file and avatar dirs on instances with no such dirs in filesystem

This commit is contained in:
Mikael Nordfeldth 2016-02-12 02:29:33 +01:00
parent 338df7e35b
commit f10625f8bc

View File

@ -191,6 +191,12 @@ class Nickname
$paths[$matches[1]] = true;
}
}
// FIXME: this assumes the 'path' is in the first-level directory, though common it's not certain
foreach (['avatar', 'attachments'] as $cat) {
$paths[basename(common_config($cat, 'path'))] = true;
}
return in_array($str, array_keys($paths));
}