@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | */ |
67 | 67 | public function __construct(WP_Post $post = null) |
68 | 68 | { |
69 | - if (! $post) { |
|
69 | + if (!$post) { |
|
70 | 70 | $post = new WP_Post(new stdClass); |
71 | 71 | $post->post_type = static::postTypeId(); |
72 | 72 | } |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | */ |
134 | 134 | public static function fromGlobal() |
135 | 135 | { |
136 | - if (! $GLOBALS['post'] instanceof WP_Post) { |
|
136 | + if (!$GLOBALS['post'] instanceof WP_Post) { |
|
137 | 137 | throw new PostNotFoundException('Global $post not an instance of WP_Post'); |
138 | 138 | } |
139 | 139 | |
@@ -239,7 +239,7 @@ discard block |
||
239 | 239 | */ |
240 | 240 | public function save() |
241 | 241 | { |
242 | - if (! $this->id) { |
|
242 | + if (!$this->id) { |
|
243 | 243 | $result = wp_insert_post($this->object->to_array(), true); |
244 | 244 | } else { |
245 | 245 | $result = wp_update_post($this->object, true); |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | */ |
38 | 38 | public function __construct(WP_User $user = null) |
39 | 39 | { |
40 | - if (! $user) { |
|
40 | + if (!$user) { |
|
41 | 41 | $user = new WP_User; |
42 | 42 | } |
43 | 43 | |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | */ |
56 | 56 | public static function fromID($id) |
57 | 57 | { |
58 | - if (! $user = get_user_by('id', $id)) { |
|
58 | + if (!$user = get_user_by('id', $id)) { |
|
59 | 59 | throw new UserNotFoundException("No user found with ID $id"); |
60 | 60 | } |
61 | 61 | |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | */ |
74 | 74 | public static function fromUsername($username) |
75 | 75 | { |
76 | - if (! $user = get_user_by('login', $username)) { |
|
76 | + if (!$user = get_user_by('login', $username)) { |
|
77 | 77 | throw new UserNotFoundException("No user found with username: $username"); |
78 | 78 | } |
79 | 79 | |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | */ |
92 | 92 | public static function fromEmail($email) |
93 | 93 | { |
94 | - if (! $user = get_user_by('email', $email)) { |
|
94 | + if (!$user = get_user_by('email', $email)) { |
|
95 | 95 | throw new UserNotFoundException("No user found with email address: $email"); |
96 | 96 | } |
97 | 97 | |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | */ |
110 | 110 | public static function fromSlug($slug) |
111 | 111 | { |
112 | - if (! $user = get_user_by('slug', $slug)) { |
|
112 | + if (!$user = get_user_by('slug', $slug)) { |
|
113 | 113 | throw new UserNotFoundException("No user found with slug: $slug"); |
114 | 114 | } |
115 | 115 | |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | */ |
147 | 147 | public function save() |
148 | 148 | { |
149 | - if (! $this->id) { |
|
149 | + if (!$this->id) { |
|
150 | 150 | $result = wp_insert_user($this->object); |
151 | 151 | } else { |
152 | 152 | $result = wp_update_user($this->object); |