Removed restoreDefaultAvatar method
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
@@ -412,25 +412,5 @@ class Setting extends Model
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Copy the default avatar back over if it's missing
|
||||
*
|
||||
* @return string
|
||||
**/
|
||||
|
||||
public static function restoreDefaultAvatar() : void {
|
||||
|
||||
if (Storage::disk('public')->missing(public_path('uploads/avatars/default.png'))) {
|
||||
\Log::debug('default avatar not found');
|
||||
try {
|
||||
Storage::disk('public')->copy(public_path('img/demo/avatars/default.png'), public_path('uploads/avatars/default.png'));
|
||||
\Log::debug('Default avatar copied back over from img/demo/default.png');
|
||||
} catch (\Exception $e) {
|
||||
\Log::debug('Could not copy default avatar. Error: '.$e);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user