[NOTE][UI] Add note replying and UI displaying

This commit is contained in:
Hugo Sales
2020-08-28 20:16:26 +00:00
committed by Hugo Sales
parent 459f0bf41f
commit 0b50905ac8
14 changed files with 203 additions and 106 deletions

View File

@@ -81,6 +81,16 @@ abstract class Common
return self::user()->getActor();
}
public static function ensureLoggedIn(): LocalUser
{
if (($user = self::user()) == null) {
throw new NoLoggedInUser();
// TODO Maybe redirect to login page and back
} else {
return $user;
}
}
/**
* Is the given string identical to a system path or route?
* This could probably be put in some other class, but at