DI::page()['aside'] = '';
}
- if (!empty($a->argv[1]) && in_array($a->argv[1], ['person', 'organisation', 'news', 'community'])) {
+ if (!empty(User::getAccountTypeByString($a->argv[1] ?? ''))) {
$accounttype = $a->argv[1];
} else {
$accounttype = '';
* Returns the numeric account type by their string
*
* @param string $accounttype as string constant
- * @return void
+ * @return int|null Numeric account type - or null when not set
*/
public static function getAccountTypeByString(string $accounttype)
{