Conditions | 5 |
Paths | 9 |
Total Lines | 44 |
Code Lines | 33 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
46 | public function deleteById($id) |
||
47 | { |
||
48 | $page = $this->where('id', $id)->first(); |
||
49 | if ($page) { |
||
50 | PageBlock::where('page_id', $page->id)->delete(); |
||
51 | if ($page->delete()) { |
||
52 | return 'success'; |
||
53 | } else { |
||
54 | return 'error'; |
||
55 | } |
||
56 | } else { |
||
57 | return 'false'; |
||
58 | } |
||
59 | } |
||
60 | |||
61 | public $translatable = ['title', 'slug']; |
||
62 | |||
63 | protected $casts = [ |
||
64 | 'meta' => 'array', |
||
65 | ]; |
||
66 | |||
67 | /** |
||
68 | * The attributes that are mass assignable. |
||
69 | * |
||
70 | * @var array |
||
71 | */ |
||
72 | protected $fillable = [ |
||
73 | 'order_column', |
||
74 | ]; |
||
75 | } |
||
76 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths