We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| 1 | <?php |
||
| 39 | class Page extends EloquentModel implements AuditInterface |
||
| 40 | { |
||
| 41 | /* |
||
| 42 | * Laravel Deleting. |
||
| 43 | * @ https://laravel.com/docs/5.5/eloquent#soft-deleting |
||
| 44 | */ |
||
| 45 | use SoftDeletes; |
||
| 46 | /* |
||
| 47 | * Laravel Audits. |
||
| 48 | * @ http://www.laravel-auditing.com |
||
| 49 | */ |
||
| 50 | use Auditable; |
||
| 51 | |||
| 52 | /** |
||
| 53 | * The table associated with the model. |
||
| 54 | * |
||
| 55 | * @var string |
||
| 56 | */ |
||
| 57 | protected $table = 'pages'; |
||
| 58 | |||
| 59 | /** |
||
| 60 | * The attributes that are mass assignable. |
||
| 61 | * |
||
| 62 | * @var array |
||
| 63 | */ |
||
| 64 | protected $fillable = ['seo_title', 'slug']; |
||
| 65 | |||
| 66 | /** |
||
| 67 | * The table date columns, casted to Carbon. |
||
| 68 | * |
||
| 69 | * @var array |
||
| 70 | */ |
||
| 71 | protected $dates = ['created_at', 'updated_at', 'deleted_at']; |
||
| 72 | |||
| 73 | /** |
||
| 74 | * Attributes to exclude from the Audit. |
||
| 75 | * |
||
| 76 | * @var array |
||
| 77 | */ |
||
| 78 | protected $auditExclude = [ |
||
| 79 | 'views', |
||
| 80 | ]; |
||
| 81 | |||
| 82 | /** |
||
| 83 | * Increment the view count of the page. |
||
| 84 | * |
||
| 85 | * @return int |
||
| 86 | */ |
||
| 87 | public function incrementViews() |
||
| 91 | |||
| 92 | /** |
||
| 93 | * A page belongs to a single menu. |
||
| 94 | * |
||
| 95 | * @return Menu|BelongsTo |
||
| 96 | */ |
||
| 97 | public function menu() |
||
| 101 | |||
| 102 | /** |
||
| 103 | * A page can have a redirect to another url, external or internal. |
||
| 104 | * |
||
| 105 | * @return Redirect|\Illuminate\Database\Eloquent\Relations\HasOne |
||
| 106 | */ |
||
| 107 | public function redirect() |
||
| 111 | |||
| 112 | /** |
||
| 113 | * Get the creator model of the eloquent model. |
||
| 114 | * |
||
| 115 | * @return Account|\Illuminate\Database\Eloquent\Relations\BelongsTo |
||
| 116 | */ |
||
| 117 | public function creator() |
||
| 121 | |||
| 122 | /** |
||
| 123 | * Get the creator model of the eloquent model. |
||
| 124 | * |
||
| 125 | * @return Account|\Illuminate\Database\Eloquent\Relations\BelongsTo |
||
| 126 | */ |
||
| 127 | public function editor() |
||
| 131 | |||
| 132 | /** |
||
| 133 | * Generate a link for the audit log. |
||
| 134 | * |
||
| 135 | * @return string |
||
| 136 | */ |
||
| 137 | public function auditTitle() |
||
| 141 | |||
| 142 | /** |
||
| 143 | * Generate a url to the audited data. |
||
| 144 | * |
||
| 145 | * @return mixed |
||
|
|
|||
| 146 | */ |
||
| 147 | public function auditUrl() |
||
| 151 | |||
| 152 | public function regenerateUrl() |
||
| 160 | } |
||
| 161 |
This check looks for the generic type
arrayas a return type and suggests a more specific type. This type is inferred from the actual code.