Conditions | 1 |
Paths | 1 |
Total Lines | 7 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Tests | 5 |
CRAP Score | 1 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
20 | 4 | public function deleteNotification($id) |
|
21 | { |
||
22 | 4 | $notification = Auth::user()->notifications()->where('id', $id)->where('notifiable_id', Auth::user()->user_id)->first(); |
|
23 | 4 | Log::debug('Deleted user notification for '.Auth::user()->full_name.'. Data - ', array($notification)); |
|
24 | 4 | $notification->delete(); |
|
25 | |||
26 | 4 | return true; |
|
27 | } |
||
29 |