From d08bb0db84537869e1f8170c5fe4145c32edee12 Mon Sep 17 00:00:00 2001 From: rtconner Date: Sun, 18 Oct 2015 21:00:28 -0400 Subject: [PATCH] Bug Fixes --- src/Model/Tag.php | 4 ++-- src/Model/Tagged.php | 1 + src/Taggable.php | 8 ++++---- src/Util.php | 4 ++-- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/Model/Tag.php b/src/Model/Tag.php index 1166b40..8edfbe6 100644 --- a/src/Model/Tag.php +++ b/src/Model/Tag.php @@ -6,8 +6,8 @@ /** * Copyright (C) 2014 Robert Conner */ -class Tag extends Eloquent { - +class Tag extends Eloquent +{ protected $table = 'tagging_tags'; public $timestamps = false; protected $softDelete = false; diff --git a/src/Model/Tagged.php b/src/Model/Tagged.php index d0d1466..2752004 100644 --- a/src/Model/Tagged.php +++ b/src/Model/Tagged.php @@ -11,6 +11,7 @@ class Tagged extends Eloquent protected $table = 'tagging_tagged'; public $timestamps = false; protected $fillable = ['tag_name', 'tag_slug']; + protected $taggingUtility; public function __construct(array $attributes = array()) { diff --git a/src/Taggable.php b/src/Taggable.php index bebec9d..c054c9a 100644 --- a/src/Taggable.php +++ b/src/Taggable.php @@ -1,11 +1,11 @@ first(); if(!$tag) { - $tag = new Tag; + $tag = new $model; $tag->name = $tagString; $tag->slug = $tagSlug; $tag->suggest = false; @@ -214,7 +214,7 @@ public function deleteUnusedTags() /** * @return string */ - public static function tagModelString() + public function tagModelString() { return config('tagging.tag_model', '\Conner\Tagging\Model\Tag'); }