adding an action for genering profile photos
This commit is contained in:
		
							
								
								
									
										28
									
								
								src/app/Actions/Chained/GenerateProfilePhoto.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								src/app/Actions/Chained/GenerateProfilePhoto.php
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,28 @@ | ||||
| <?php | ||||
|  | ||||
| namespace App\Actions\Chained; | ||||
|  | ||||
| use App\Models\User; | ||||
| use Closure; | ||||
|  | ||||
| class GenerateProfilePhoto | ||||
| { | ||||
|     /** | ||||
|      * Generates a profile photo for a user and saves it | ||||
|      * to disk. | ||||
|      * | ||||
|      * @package App\Actions\Chained\GenerateProfilePhoto | ||||
|      * @since   1.0.0 | ||||
|      * | ||||
|      * @param \App\Models\User $user | ||||
|      * @param \Closure         $next | ||||
|      * | ||||
|      * @return \App\Models\User | ||||
|      */ | ||||
|     public function __invoke(User $user, Closure $next): User | ||||
|     { | ||||
|         // | ||||
|  | ||||
|         return $next($user); | ||||
|     } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user