Completed
Push — master ( 71cd39...d95db8 )
by Evan
15s
created
src/Term/Model.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
     /**
43 43
      * Model Constructor.
44 44
      *
45
-     * @param mixed $term  WP_Term to fill data from
45
+     * @param null|WP_Term $term  WP_Term to fill data from
46 46
      */
47 47
     public function __construct(WP_Term $term = null)
48 48
     {
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
      */
47 47
     public function __construct(WP_Term $term = null)
48 48
     {
49
-        if (! $term) {
49
+        if ( ! $term) {
50 50
             $term = new WP_Term(new stdClass);
51 51
             $term->taxonomy = static::TAXONOMY;
52 52
         } elseif ($term->taxonomy != static::TAXONOMY) {
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
      */
78 78
     public static function fromID($id)
79 79
     {
80
-        if (! $term = get_term_by('id', (int) $id, static::TAXONOMY)) {
80
+        if ( ! $term = get_term_by('id', (int) $id, static::TAXONOMY)) {
81 81
             throw new TermNotFoundException("No term found with ID $id.");
82 82
         }
83 83
 
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
      */
94 94
     public static function fromSlug($slug)
95 95
     {
96
-        if (! $term = get_term_by('slug', $slug, static::TAXONOMY)) {
96
+        if ( ! $term = get_term_by('slug', $slug, static::TAXONOMY)) {
97 97
             throw new TermNotFoundException("No term found with slug '$slug'.");
98 98
         }
99 99
 
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
     public function ancestors()
220 220
     {
221 221
         return Collection::make(get_ancestors($this->id, static::TAXONOMY, 'taxonomy'))
222
-            ->map(function ($term_ID) {
222
+            ->map(function($term_ID) {
223 223
                 return static::fromID($term_ID);
224 224
             });
225 225
     }
Please login to merge, or discard this patch.
src/Taxonomy/Taxonomy.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
     public function postTypes()
104 104
     {
105 105
         return Collection::make($this->object_type)
106
-            ->map(function ($post_type) {
106
+            ->map(function($post_type) {
107 107
                 return PostType::load($post_type);
108 108
             });
109 109
     }
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
      */
116 116
     public function unregister()
117 117
     {
118
-        if (! static::exists($this->taxonomy->name)) {
118
+        if ( ! static::exists($this->taxonomy->name)) {
119 119
             throw new Exception\NonExistentTaxonomyException;
120 120
         }
121 121
 
Please login to merge, or discard this patch.
src/Term/TermQueryBuilder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@
 block discarded – undo
106 106
         $modelClass = get_class($this->model);
107 107
 
108 108
         return Collection::make($this->fetchTerms())
109
-            ->map(function (WP_Term $term) use ($modelClass) {
109
+            ->map(function(WP_Term $term) use ($modelClass) {
110 110
                 return new $modelClass($term);
111 111
             });
112 112
     }
Please login to merge, or discard this patch.