| Conditions | 3 |
| Paths | 4 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | public function indexPayment() |
||
| 14 | { |
||
| 15 | $payments = config('adminetic.caching', true) |
||
| 16 | ? (Cache::has('payments') ? Cache::get('payments') : Cache::rememberForever('payments', function () { |
||
| 17 | return Payment::orderBy('position')->get(); |
||
| 18 | })) |
||
| 19 | : Payment::orderBy('position')->get(); |
||
| 20 | |||
| 21 | return compact('payments'); |
||
| 22 | } |
||
| 60 |