mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-24 05:04:07 -08:00
Added some debugging - will remove at RC
This commit is contained in:
parent
041fc20955
commit
66686f8080
|
@ -121,13 +121,17 @@ class ImageUploadRequest extends Request
|
|||
}
|
||||
|
||||
// If the user isn't uploading anything new but wants to delete their old image, do so
|
||||
} elseif ($this->input('image_delete')=='1') {
|
||||
} else {
|
||||
\Log::debug('No image was passed - not sure what to do now.');
|
||||
if ($this->input('image_delete')=='1') {
|
||||
|
||||
try {
|
||||
Storage::disk('public')->delete($path.'/'.$item->{$fieldname});
|
||||
$item->{$fieldname} = null;
|
||||
} catch (\Exception $e) {
|
||||
\Log::debug($e);
|
||||
|
||||
try {
|
||||
Storage::disk('public')->delete($path . '/' . $item->{$fieldname});
|
||||
$item->{$fieldname} = null;
|
||||
} catch (\Exception $e) {
|
||||
\Log::debug($e);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue