create-prisma-php-app 4.3.2 → 4.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,6 @@ use PP\Request;
15
15
  use Exception;
16
16
  use InvalidArgumentException;
17
17
  use ArrayObject;
18
- use Lib\Prisma\Classes\UserData;
19
18
 
20
19
  class Auth
21
20
  {
@@ -220,15 +219,15 @@ class Auth
220
219
  * Refreshes the current user's session if the provided User ID matches the currently authenticated user.
221
220
  * This allows silent updates of permissions or profile data without requiring a logout.
222
221
  * @param string $targetUserId The ID of the user being updated.
223
- * @param mixed $newUserData The fresh user object (e.g. from Prisma) to replace the session payload.
222
+ * @param mixed $newmixed The fresh user object (e.g. from Prisma) to replace the session payload.
224
223
  * @return bool Returns true if the session was updated, false if the IDs did not match or no session exists.
225
224
  */
226
- public function refreshUserSession(string $targetUserId, mixed $newUserData): bool
225
+ public function refreshUserSession(string $targetUserId, mixed $newmixed): bool
227
226
  {
228
227
  $currentUser = $this->getPayload();
229
228
 
230
229
  if ($currentUser && isset($currentUser->id) && $currentUser->id === $targetUserId) {
231
- $this->signIn($newUserData, null, false);
230
+ $this->signIn($newmixed, null, false);
232
231
  return true;
233
232
  }
234
233
 
@@ -308,7 +307,7 @@ class Auth
308
307
  * Returns the role of the authenticated user based on the payload stored in the session.
309
308
  * If the user is not authenticated, null is returned.
310
309
  *
311
- * @return UserData|null Returns the role of the authenticated user or null if the user is not authenticated.
310
+ * @return mixed|null Returns the role of the authenticated user or null if the user is not authenticated.
312
311
  */
313
312
  public function getPayload()
314
313
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-prisma-php-app",
3
- "version": "4.3.2",
3
+ "version": "4.3.3",
4
4
  "description": "Prisma-PHP: A Revolutionary Library Bridging PHP with Prisma ORM",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",