DeleteUser
in package
Table of Contents
Properties
Methods
- __construct() : mixed
- execute() : array{success: bool, error?: string}
- Delete a user.
Properties
$userRepository
private
UserRepositoryInterface
$userRepository
Methods
__construct()
public
__construct(UserRepositoryInterface $userRepository) : mixed
Parameters
- $userRepository : UserRepositoryInterface
execute()
Delete a user.
public
execute(int $userId, int $currentAdminId) : array{success: bool, error?: string}
Parameters
- $userId : int
-
The user to delete
- $currentAdminId : int
-
The admin performing the deletion