]> BookStack Code Mirror - bookstack/blobdiff - app/Auth/Permissions/JointPermission.php
Update Localization.php in Middleware with "no" tag for estimate.
[bookstack] / app / Auth / Permissions / JointPermission.php
index 71c1979fcf579516c6527cacb29c6c1f027ebf14..8d1776bd8a45ad59d74d417a82b370ccf20b1fa0 100644 (file)
@@ -1,27 +1,28 @@
 <?php namespace BookStack\Auth\Permissions;
 
+use BookStack\Auth\Role;
 use BookStack\Entities\Entity;
 use BookStack\Model;
-use BookStack\Auth\Role;
+use Illuminate\Database\Eloquent\Relations\BelongsTo;
+use Illuminate\Database\Eloquent\Relations\MorphOne;
 
 class JointPermission extends Model
 {
+    protected $primaryKey = null;
     public $timestamps = false;
 
     /**
      * Get the role that this points to.
-     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
      */
-    public function role()
+    public function role(): BelongsTo
     {
         return $this->belongsTo(Role::class);
     }
 
     /**
      * Get the entity this points to.
-     * @return \Illuminate\Database\Eloquent\Relations\MorphOne
      */
-    public function entity()
+    public function entity(): MorphOne
     {
         return $this->morphOne(Entity::class, 'entity');
     }