title: Laravel - voyager BREAD
body: <p>I started my simple laravel project with posts. First I created my auth, than my posts and everything works fine. But I installed voyager admin panel(without dummy) in my project and I add BREAD to posts table, but when I try to Edit some of my posts it shows me an error: <code>Call to undefined method App\Post::getTranslationsOf() (View: C:\engineering\xampp\htdocs\lsappdev\vendor\tcg\voyager\resources\views\posts\edit-add.blade.php)</code>. Why is this error showing?
  Here is my <code>PostsController</code>:</p>
  
  <pre><code>&lt;?php
  
  namespace App\Http\Controllers;
  
  use Illuminate\Http\Request;
  use Illuminate\Support\Facades\Storage;
  use App\Post;
  use DB;
  
  class PostsController extends Controller
  {
  
      /**
       * Create a new controller instance.
       *
       * @return void
       */
      public function __construct()
      {
          $this-&gt;middleware('auth', ['except' =&gt; ['index', 'show']]);
      }
  
  
      /**
       * Display a listing of the resource.
       *
       * @return \Illuminate\Http\Response
       */
      public function index()
      {
          $posts = Post::all();
          return view('posts.index')-&gt;with('posts', $posts);
      }
  
      /**
       * Show the form for creating a new resource.
       *
       * @return \Illuminate\Http\Response
       */
      public function create()
      {
          return view('posts.create');
      }
  
      /**
       * Store a newly created resource in storage.
       *
       * @param  \Illuminate\Http\Request  $request
       * @return \Illuminate\Http\Response
       */
      public function store(Request $request)
      {
          $this-&gt;validate($request, [
              'title' =&gt; 'required',
              'description' =&gt; 'required',
              'cover_image' =&gt; 'image|nullable|max:1999'
          ]);
  
          // Handle File Upload
          if($request-&gt;hasFile('cover_image')){
              // Get filename with the extension
              $filenameWithExt = $request-&gt;file('cover_image')-&gt;getClientOriginalName();
              // Get just filename
              $filename = pathinfo($filenameWithExt, PATHINFO_FILENAME);
              // Get just ext
              $extension = $request-&gt;file('cover_image')-&gt;getClientOriginalExtension();
              // Filename to store
              $fileNameToStore= $filename.'_'.time().'.'.$extension;
              // Upload Image
              $path = $request-&gt;file('cover_image')-&gt;storeAs('public/cover_images', $fileNameToStore);
          } else {
              $fileNameToStore = 'noimage.jpg';
          }
  
          $post = new Post;
          $post-&gt;title = $request-&gt;input('title');
          $post-&gt;description = $request-&gt;input('title');
          $post-&gt;user_id = auth()-&gt;user()-&gt;id;
          $post-&gt;cover_image = $fileNameToStore;
          $post-&gt;save();
  
          return redirect('/posts');
      }
  
      /**
       * Display the specified resource.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function show($id)
      {
          $post = Post::find($id);
          return view('posts.show')-&gt;with('post', $post);
      }
  
      /**
       * Show the form for editing the specified resource.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function edit($id)
      {
          $post = Post::find($id);
  
          //Check if post exists before deleting
          if (!isset($post)){
              return redirect('/posts')-&gt;with('error', 'No Post Found');
          }
  
          // Check for correct user
          if(auth()-&gt;user()-&gt;id !==$post-&gt;user_id){
              return redirect('/posts')-&gt;with('error', 'Unauthorized Page');
          }
  
  
          return view('posts.edit')-&gt;with('post', $post);
      }
  
      /**
       * Update the specified resource in storage.
       *
       * @param  \Illuminate\Http\Request  $request
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function update(Request $request, $id)
      {
          $this-&gt;validate($request, [
              'title' =&gt; 'required',
              'body' =&gt; 'required',
              'cover_image' =&gt; 'image|nullable|max:1999'
          ]);
  
          $post = Post::find($id);
           // Handle File Upload
          if($request-&gt;hasFile('cover_image')){
              // Get filename with the extension
              $filenameWithExt = $request-&gt;file('cover_image')-&gt;getClientOriginalName();
              // Get just filename
              $filename = pathinfo($filenameWithExt, PATHINFO_FILENAME);
              // Get just ext
              $extension = $request-&gt;file('cover_image')-&gt;getClientOriginalExtension();
              // Filename to store
              $fileNameToStore= $filename.'_'.time().'.'.$extension;
              // Upload Image
              $path = $request-&gt;file('cover_image')-&gt;storeAs('public/cover_images', $fileNameToStore);
              // Delete file if exists
              Storage::delete('public/cover_images/'.$post-&gt;cover_image);
          }
  
          $post-&gt;title = $request-&gt;input('title');
          $post-&gt;body = $request-&gt;input('description');
          if($request-&gt;hasFile('cover_image')){
              $post-&gt;cover_image = $fileNameToStore;
          }
          $post-&gt;save();
  
          return 123;
      }
  
      /**
       * Remove the specified resource from storage.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function destroy($id)
      {
          $post = Post::find($id);
  
          //Check if post exists before deleting
          if (!isset($post)){
              return redirect('/posts')-&gt;with('error', 'No Post Found');
          }
  
          // Check for correct user
          if(auth()-&gt;user()-&gt;id !==$post-&gt;user_id){
              return redirect('/posts')-&gt;with('error', 'Unauthorized Page');
          }
  
          if($post-&gt;cover_image != 'noimage.jpg'){
              // Delete Image
              Storage::delete('public/cover_images/'.$post-&gt;cover_image);
          }
  
          $post-&gt;delete();
          return redirect('/posts');
      }
  }
  </code></pre>
  
  <p>And here is my <code>Post.php</code> model:</p>
  
  <pre><code>&lt;?php
  
  namespace App;
  
  use Illuminate\Database\Eloquent\Model;
  use Laravelista\Comments\Commentable;
  
  class Post extends Model
  {
      use Commentable;
  
      protected $table = 'posts';
  
      protected $primaryKey = 'id';
  
      protected $fillable = ['title', 'description', 'cover_image', 'user_id'];
  
      public function user(){
          return $this-&gt;belongsTo(User::class);
      }
  }
  </code></pre>
  
  <p>Please if anybody know a solution for this error help! Everything worked fine before I installed Voyager in my project.</p>