We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ed05a31 commit 3bd5f8aCopy full SHA for 3bd5f8a
1 file changed
lib/User.php
@@ -249,6 +249,15 @@ public static function getUserById($userId) {
249
return false;
250
}
251
252
+ public static function getUserByWebId($webId) {
253
+ $idParts = explode(".", $webId, 2);
254
+ if ($idParts[1] !== BASEDOMAIN . "/#me") {
255
+ return false;
256
+ }
257
+ $userId = preg_replace("/^id-/", "", $idParts[0]);
258
+ return self::getUserById($userId);
259
260
+
261
public static function checkPassword($email, $password) {
262
Db::connect();
263
$query = Db::$pdo->prepare(
0 commit comments