private function buildPostObject()
    {
        $hash = $this->auth_user->hash;
        $cached_post = $this->cache->get("autoSavedPost-$hash");

        $post = [];
        $post['hash'] = '';
        $post['title'] = $cached_post['title'];
        $post['slug'] = $cached_post['slug'];
        $post['content'] = $cached_post['content'];
        $post['publish_date'] = $cached_post['publishdate'];
        $post['status_id'] = $this->status->byHash($cached_post['status'])->id;
        $post['visibility_id'] = $this->visibility->byHash($cached_post['visibility'])->id;
        $post['reviewer_id'] = $this->user->byHash($cached_post['reviewer'])->id;
        $post['category_id'] = $this->category->byHash($cached_post['category'])->id;
        $post['tag'] = $this->buildTagsArrayForPostObject($cached_post['tags']);

        return objectify($post);
    }
private function buildPostObject()
    {
        $hash = $this->auth_user->hash;
        $cached_post = $this->cache->get("autoSavedPost-$hash");

        $post = [];
        $post['hash'] = '';
        $post['title'] = $cached_post['title'];
        $post['slug'] = $cached_post['slug'];
        $post['content'] = $cached_post['content'];
        $post['publish_date'] = $cached_post['publishdate'];
        $post['status_id'] = $this->status->byHash($cached_post['status'])->id;
        $post['visibility_id'] = $this->visibility->byHash($cached_post['visibility'])->id;
        $post['reviewer_id'] = $this->user->byHash($cached_post['reviewer'])->id;
        $post['category_id'] = $this->category->byHash($cached_post['category'])->id;
        $post['tag'] = $this->buildTagsArrayForPostObject($cached_post['tags']);

        return objectify($post);
    }
private function buildPostObject ( ) { $ hash = $ this -> auth_user -> hash ; $ cached_post = $ this -> cache -> get ( "autoSavedPost-$hash" ) ; $ post = [ ] ; $ post [ 'hash' ] = '' ; $ post [ 'title' ] = $ cached_post [ 'title' ] ; $ post [ 'slug' ] = $ cached_post [ 'slug' ] ; $ post [ 'content' ] = $ cached_post [ 'content' ] ; $ post [ 'publish_date' ] = $ cached_post [ 'publishdate' ] ; $ post [ 'status_id' ] = $ this -> status -> byHash ( $ cached_post [ 'status' ] ) -> id ; $ post [ 'visibility_id' ] = $ this -> visibility -> byHash ( $ cached_post [ 'visibility' ] ) -> id ; $ post [ 'reviewer_id' ] = $ this -> user -> byHash ( $ cached_post [ 'reviewer' ] ) -> id ; $ post [ 'category_id' ] = $ this -> category -> byHash ( $ cached_post [ 'category' ] ) -> id ; $ post [ 'tag' ] = $ this -> buildTagsArrayForPostObject ( $ cached_post [ 'tags' ] ) ; return objectify ( $ post ) ; }
Build a post object when there
is a cached post so we can put
the data back in the form

@return object
Build a post object when there is a cached post so we can put the data back in the form