@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | * |
41 | 41 | * @return OrganizationExport |
42 | 42 | */ |
43 | - public function export () { |
|
43 | + public function export() { |
|
44 | 44 | /** @var OrganizationExport $export */ |
45 | 45 | $export = $this->api->factory($this, OrganizationExport::class); |
46 | 46 | $export->_set('organization', $this); |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | * @param int $limit 1-100 |
62 | 62 | * @return array|AbstractEntity[] |
63 | 63 | */ |
64 | - protected function find (string $class, string $text, int $limit = 20) { |
|
64 | + protected function find(string $class, string $text, int $limit = 20) { |
|
65 | 65 | return $this->api->loadAll($this, $class, "{$this}/typeahead", [ |
66 | 66 | 'resource_type' => $class::TYPE, |
67 | 67 | 'query' => $text, |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | * @param int $limit 1-100 |
77 | 77 | * @return CustomField[] |
78 | 78 | */ |
79 | - public function findCustomFields (string $text, int $limit = 20) { |
|
79 | + public function findCustomFields(string $text, int $limit = 20) { |
|
80 | 80 | return $this->find(CustomField::class, $text, $limit); |
81 | 81 | } |
82 | 82 | |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | * @param int $limit 1-100 |
88 | 88 | * @return Portfolio[] |
89 | 89 | */ |
90 | - public function findPortfolios (string $text, int $limit = 20) { |
|
90 | + public function findPortfolios(string $text, int $limit = 20) { |
|
91 | 91 | return $this->find(Portfolio::class, $text, $limit); |
92 | 92 | } |
93 | 93 | |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | * @param int $limit 1-100 |
99 | 99 | * @return Project[] |
100 | 100 | */ |
101 | - public function findProjects (string $text, int $limit = 20) { |
|
101 | + public function findProjects(string $text, int $limit = 20) { |
|
102 | 102 | return $this->find(Project::class, $text, $limit); |
103 | 103 | } |
104 | 104 | |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | * @param int $limit 1-100 |
110 | 110 | * @return Tag[] |
111 | 111 | */ |
112 | - public function findTags (string $text, int $limit = 20) { |
|
112 | + public function findTags(string $text, int $limit = 20) { |
|
113 | 113 | return $this->find(Tag::class, $text, $limit); |
114 | 114 | } |
115 | 115 | |
@@ -120,14 +120,14 @@ discard block |
||
120 | 120 | * @param int $limit 1-100 |
121 | 121 | * @return Task[] |
122 | 122 | */ |
123 | - public function findTasks (string $text, int $limit = 20) { |
|
123 | + public function findTasks(string $text, int $limit = 20) { |
|
124 | 124 | return $this->find(Task::class, $text, $limit); |
125 | 125 | } |
126 | 126 | |
127 | 127 | /** |
128 | 128 | * @return CustomField[] |
129 | 129 | */ |
130 | - public function getCustomFields () { |
|
130 | + public function getCustomFields() { |
|
131 | 131 | return $this->api->loadAll($this, CustomField::class, "{$this}/custom_fields"); |
132 | 132 | } |
133 | 133 | |
@@ -136,7 +136,7 @@ discard block |
||
136 | 136 | * |
137 | 137 | * @return Portfolio[] |
138 | 138 | */ |
139 | - public function getPortfolios () { |
|
139 | + public function getPortfolios() { |
|
140 | 140 | return $this->api->loadAll($this, Portfolio::class, "portfolios", [ |
141 | 141 | 'workspace' => $this->getGid(), |
142 | 142 | 'owner' => $this->api->getMe()->getGid() // the only allowed value, but still required. |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | * @param array $filter |
150 | 150 | * @return Project[] |
151 | 151 | */ |
152 | - public function getProjects (array $filter = Project::GET_ACTIVE) { |
|
152 | + public function getProjects(array $filter = Project::GET_ACTIVE) { |
|
153 | 153 | $filter['workspace'] = $this->getGid(); |
154 | 154 | return $this->api->loadAll($this, Project::class, 'projects', $filter); |
155 | 155 | } |
@@ -157,14 +157,14 @@ discard block |
||
157 | 157 | /** |
158 | 158 | * @return Tag[] |
159 | 159 | */ |
160 | - public function getTags () { |
|
160 | + public function getTags() { |
|
161 | 161 | return $this->api->loadAll($this, Tag::class, 'tags', ['workspace' => $this->getGid()]); |
162 | 162 | } |
163 | 163 | |
164 | 164 | /** |
165 | 165 | * @return Team[] |
166 | 166 | */ |
167 | - public function getTeams () { |
|
167 | + public function getTeams() { |
|
168 | 168 | return $this->api->loadAll($this, Team::class, "organizations/{$this->getGid()}/teams"); |
169 | 169 | } |
170 | 170 | |
@@ -172,7 +172,7 @@ discard block |
||
172 | 172 | * @param string $email |
173 | 173 | * @return null|User |
174 | 174 | */ |
175 | - public function getUserByEmail (string $email) { |
|
175 | + public function getUserByEmail(string $email) { |
|
176 | 176 | return $this->api->getPool()->get("users/{$email}", $this, function() use ($email) { |
177 | 177 | foreach ($this->getUsers() as $user) { |
178 | 178 | if ($user->getEmail() === $email) { |
@@ -186,14 +186,14 @@ discard block |
||
186 | 186 | /** |
187 | 187 | * @return User[] |
188 | 188 | */ |
189 | - public function getUsers () { |
|
189 | + public function getUsers() { |
|
190 | 190 | return $this->api->loadAll($this, User::class, "{$this}/users"); |
191 | 191 | } |
192 | 192 | |
193 | 193 | /** |
194 | 194 | * @return ProjectWebhook[]|TaskWebhook[] |
195 | 195 | */ |
196 | - public function getWebhooks () { |
|
196 | + public function getWebhooks() { |
|
197 | 197 | return array_map(function(array $each) { |
198 | 198 | return $this->api->getPool()->get($each['gid'], $this, function() use ($each) { |
199 | 199 | return $this->api->factory($this, [ |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | /** |
211 | 211 | * @return bool |
212 | 212 | */ |
213 | - final public function isOrganization (): bool { |
|
213 | + final public function isOrganization(): bool { |
|
214 | 214 | return $this->_is('is_organization'); |
215 | 215 | } |
216 | 216 | |
@@ -219,7 +219,7 @@ discard block |
||
219 | 219 | * |
220 | 220 | * @return CustomField |
221 | 221 | */ |
222 | - public function newCustomField () { |
|
222 | + public function newCustomField() { |
|
223 | 223 | /** @var CustomField $field */ |
224 | 224 | $field = $this->api->factory($this, CustomField::class); |
225 | 225 | return $field->setWorkspace($this); |
@@ -230,7 +230,7 @@ discard block |
||
230 | 230 | * |
231 | 231 | * @return Portfolio |
232 | 232 | */ |
233 | - public function newPortfolio () { |
|
233 | + public function newPortfolio() { |
|
234 | 234 | /** @var Portfolio $portfolio */ |
235 | 235 | $portfolio = $this->api->factory($this, Portfolio::class); |
236 | 236 | return $portfolio->setWorkspace($this); |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | * |
242 | 242 | * @return Project |
243 | 243 | */ |
244 | - public function newProject () { |
|
244 | + public function newProject() { |
|
245 | 245 | /** @var Project $project */ |
246 | 246 | $project = $this->api->factory($this, Project::class); |
247 | 247 | return $project->setWorkspace($this); |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | * |
253 | 253 | * @return Tag |
254 | 254 | */ |
255 | - public function newTag () { |
|
255 | + public function newTag() { |
|
256 | 256 | /** @var Tag $tag */ |
257 | 257 | $tag = $this->api->factory($this, Tag::class); |
258 | 258 | return $tag->setWorkspace($this); |
@@ -263,7 +263,7 @@ discard block |
||
263 | 263 | * |
264 | 264 | * @return Task |
265 | 265 | */ |
266 | - public function newTask () { |
|
266 | + public function newTask() { |
|
267 | 267 | /** @var Task $task */ |
268 | 268 | $task = $this->api->factory($this, Task::class); |
269 | 269 | return $task->setWorkspace($this); |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | * |
41 | 41 | * @return bool |
42 | 42 | */ |
43 | - final public function isActive (): bool { |
|
43 | + final public function isActive(): bool { |
|
44 | 44 | return $this->getStatus() === self::STATUS_ACTIVE; |
45 | 45 | } |
46 | 46 | |
@@ -49,21 +49,21 @@ discard block |
||
49 | 49 | * |
50 | 50 | * @return bool |
51 | 51 | */ |
52 | - final public function isDone (): bool { |
|
52 | + final public function isDone(): bool { |
|
53 | 53 | return $this->isSuccessful() or $this->isFailed(); |
54 | 54 | } |
55 | 55 | |
56 | 56 | /** |
57 | 57 | * @return bool |
58 | 58 | */ |
59 | - final public function isDuplicatingProject (): bool { |
|
59 | + final public function isDuplicatingProject(): bool { |
|
60 | 60 | return $this->getResourceSubtype() === self::TYPE_DUPLICATE_PROJECT; |
61 | 61 | } |
62 | 62 | |
63 | 63 | /** |
64 | 64 | * @return bool |
65 | 65 | */ |
66 | - final public function isDuplicatingTask (): bool { |
|
66 | + final public function isDuplicatingTask(): bool { |
|
67 | 67 | return $this->getResourceSubtype() === self::TYPE_DUPLICATE_TASK; |
68 | 68 | } |
69 | 69 | |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | * |
73 | 73 | * @return bool |
74 | 74 | */ |
75 | - final public function isFailed (): bool { |
|
75 | + final public function isFailed(): bool { |
|
76 | 76 | return $this->getStatus() === self::STATUS_FAIL; |
77 | 77 | } |
78 | 78 | |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | * |
82 | 82 | * @return bool |
83 | 83 | */ |
84 | - final public function isQueued (): bool { |
|
84 | + final public function isQueued(): bool { |
|
85 | 85 | return $this->getStatus() === self::STATUS_QUEUED; |
86 | 86 | } |
87 | 87 | |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | * |
91 | 91 | * @return bool |
92 | 92 | */ |
93 | - final public function isSuccessful (): bool { |
|
93 | + final public function isSuccessful(): bool { |
|
94 | 94 | return $this->getStatus() === self::STATUS_SUCCESS; |
95 | 95 | } |
96 | 96 | |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | * @param callable $spinner `fn( Job $this ): void` |
103 | 103 | * @return $this |
104 | 104 | */ |
105 | - public function wait (callable $spinner = null) { |
|
105 | + public function wait(callable $spinner = null) { |
|
106 | 106 | while (!$this->isDone()) { |
107 | 107 | if ($spinner) { |
108 | 108 | call_user_func($spinner, $this); |
@@ -36,11 +36,11 @@ discard block |
||
36 | 36 | * @param array $filter |
37 | 37 | * @return Traversable|Task[] |
38 | 38 | */ |
39 | - public function getIterator (array $filter = Task::GET_INCOMPLETE) { |
|
39 | + public function getIterator(array $filter = Task::GET_INCOMPLETE) { |
|
40 | 40 | return $this->api->loadEach($this, Task::class, "{$this}/tasks", $filter); |
41 | 41 | } |
42 | 42 | |
43 | - public function getPoolKeys () { |
|
43 | + public function getPoolKeys() { |
|
44 | 44 | $keys = parent::getPoolKeys(); |
45 | 45 | |
46 | 46 | /** @see User::getTaskList() */ |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | * @param array $filter |
58 | 58 | * @return Task[] |
59 | 59 | */ |
60 | - public function getTasks (array $filter = Task::GET_INCOMPLETE) { |
|
60 | + public function getTasks(array $filter = Task::GET_INCOMPLETE) { |
|
61 | 61 | return iterator_to_array($this->getIterator($filter)); |
62 | 62 | } |
63 | 63 | |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | * @param array $apiFilter Given to the API to reduce network load. |
67 | 67 | * @return Task[] |
68 | 68 | */ |
69 | - public function selectTasks (callable $filter, array $apiFilter = Task::GET_INCOMPLETE) { |
|
69 | + public function selectTasks(callable $filter, array $apiFilter = Task::GET_INCOMPLETE) { |
|
70 | 70 | return $this->_select($this->getIterator($apiFilter), $filter); |
71 | 71 | } |
72 | 72 | } |
73 | 73 | \ No newline at end of file |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | * @param array $filter |
44 | 44 | * @return Traversable|Task[] |
45 | 45 | */ |
46 | - public function getIterator (array $filter = Task::GET_INCOMPLETE) { |
|
46 | + public function getIterator(array $filter = Task::GET_INCOMPLETE) { |
|
47 | 47 | return $this->api->loadEach($this, Task::class, "{$this}/tasks", $filter); |
48 | 48 | } |
49 | 49 | |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | * @param array $filter |
52 | 52 | * @return Task[] |
53 | 53 | */ |
54 | - public function getTasks (array $filter = Task::GET_INCOMPLETE) { |
|
54 | + public function getTasks(array $filter = Task::GET_INCOMPLETE) { |
|
55 | 55 | return iterator_to_array($this->getIterator($filter)); |
56 | 56 | } |
57 | 57 | } |
58 | 58 | \ No newline at end of file |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | 'enum_options' => [EnumOption::class], |
45 | 45 | ]; |
46 | 46 | |
47 | - protected function _setData (array $data): void { |
|
47 | + protected function _setData(array $data): void { |
|
48 | 48 | // strip out field entry values if present. |
49 | 49 | $data = array_intersect_key($data, array_flip([ |
50 | 50 | 'gid', |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | * @param string $name |
66 | 66 | * @return EnumOption |
67 | 67 | */ |
68 | - public function addEnumOption (string $name) { |
|
68 | + public function addEnumOption(string $name) { |
|
69 | 69 | /** @var EnumOption $option */ |
70 | 70 | $option = $this->api->factory($this, EnumOption::class); |
71 | 71 | $option->setName($name); |
@@ -81,35 +81,35 @@ discard block |
||
81 | 81 | /** |
82 | 82 | * @return bool |
83 | 83 | */ |
84 | - final public function hasNotificationsEnabled (): bool { |
|
84 | + final public function hasNotificationsEnabled(): bool { |
|
85 | 85 | return $this->_is('has_notifications_enabled'); |
86 | 86 | } |
87 | 87 | |
88 | 88 | /** |
89 | 89 | * @return bool |
90 | 90 | */ |
91 | - final public function isEnum (): bool { |
|
91 | + final public function isEnum(): bool { |
|
92 | 92 | return $this->getResourceSubtype() === self::TYPE_ENUM; |
93 | 93 | } |
94 | 94 | |
95 | 95 | /** |
96 | 96 | * @return bool |
97 | 97 | */ |
98 | - final public function isGlobalToWorkspace (): bool { |
|
98 | + final public function isGlobalToWorkspace(): bool { |
|
99 | 99 | return $this->_is('is_global_to_workspace'); |
100 | 100 | } |
101 | 101 | |
102 | 102 | /** |
103 | 103 | * @return bool |
104 | 104 | */ |
105 | - final public function isNumber (): bool { |
|
105 | + final public function isNumber(): bool { |
|
106 | 106 | return $this->getResourceSubtype() === self::TYPE_NUMBER; |
107 | 107 | } |
108 | 108 | |
109 | 109 | /** |
110 | 110 | * @return bool |
111 | 111 | */ |
112 | - final public function isText (): bool { |
|
112 | + final public function isText(): bool { |
|
113 | 113 | return $this->getResourceSubtype() === self::TYPE_TEXT; |
114 | 114 | } |
115 | 115 | |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | * @param bool $flag |
118 | 118 | * @return $this |
119 | 119 | */ |
120 | - final public function setGlobalToWorkspace (bool $flag) { |
|
120 | + final public function setGlobalToWorkspace(bool $flag) { |
|
121 | 121 | return $this->_set('is_global_to_workspace', $flag); |
122 | 122 | } |
123 | 123 | |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | * @param bool $flag |
126 | 126 | * @return $this |
127 | 127 | */ |
128 | - final public function setNotificationsEnabled (bool $flag) { |
|
128 | + final public function setNotificationsEnabled(bool $flag) { |
|
129 | 129 | return $this->_set('has_notifications_enabled', $flag); |
130 | 130 | } |
131 | 131 | |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | * @param callable $cmp `fn( EnumOption $a, EnumOption $b ): int` |
134 | 134 | * @return $this |
135 | 135 | */ |
136 | - public function sortEnumOptions (callable $cmp) { |
|
136 | + public function sortEnumOptions(callable $cmp) { |
|
137 | 137 | if ($options = $this->getEnumOptions()) { |
138 | 138 | $prev = $options[0]; // first option on remote |
139 | 139 | usort($options, $cmp); |
@@ -51,12 +51,12 @@ discard block |
||
51 | 51 | * @param Project $project |
52 | 52 | * @param array $data |
53 | 53 | */ |
54 | - public function __construct (Project $project, array $data = []) { |
|
54 | + public function __construct(Project $project, array $data = []) { |
|
55 | 55 | $this->parent = $project; |
56 | 56 | parent::__construct($project, $data); |
57 | 57 | } |
58 | 58 | |
59 | - protected function _setData (array $data): void { |
|
59 | + protected function _setData(array $data): void { |
|
60 | 60 | // redundant, prefer created_by |
61 | 61 | unset($data['author']); |
62 | 62 | |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | /** |
67 | 67 | * @return Project |
68 | 68 | */ |
69 | - public function getProject () { |
|
69 | + public function getProject() { |
|
70 | 70 | return $this->parent; |
71 | 71 | } |
72 | 72 | } |
73 | 73 | \ No newline at end of file |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | */ |
38 | 38 | protected $parent; |
39 | 39 | |
40 | - public function __construct ($caller, array $data = []) { |
|
40 | + public function __construct($caller, array $data = []) { |
|
41 | 41 | parent::__construct($caller, $data); |
42 | 42 | $this->parent = $this->getProject(); |
43 | 43 | } |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | * @param array $filter |
47 | 47 | * @return Traversable|Task[] |
48 | 48 | */ |
49 | - public function getIterator (array $filter = Task::GET_INCOMPLETE) { |
|
49 | + public function getIterator(array $filter = Task::GET_INCOMPLETE) { |
|
50 | 50 | $filter['section'] = $this->getGid(); |
51 | 51 | return $this->api->loadEach($this, Task::class, 'tasks', $filter); |
52 | 52 | } |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | * @param array $filter |
56 | 56 | * @return Task[] |
57 | 57 | */ |
58 | - public function getTasks (array $filter = Task::GET_INCOMPLETE) { |
|
58 | + public function getTasks(array $filter = Task::GET_INCOMPLETE) { |
|
59 | 59 | return iterator_to_array($this->getIterator($filter)); |
60 | 60 | } |
61 | 61 | |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | * @depends after-create |
66 | 66 | * @return Task |
67 | 67 | */ |
68 | - public function newTask () { |
|
68 | + public function newTask() { |
|
69 | 69 | /** @var Task $task */ |
70 | 70 | $task = $this->api->factory($this, Task::class); |
71 | 71 | return $task->addToProject($this); |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | * @param Project $item |
65 | 65 | * @return $this |
66 | 66 | */ |
67 | - public function addItem (Project $item) { |
|
67 | + public function addItem(Project $item) { |
|
68 | 68 | $this->api->post("{$this}/addItem", ['item' => $item->getGid()]); |
69 | 69 | return $this; |
70 | 70 | } |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | * @param User $user |
74 | 74 | * @return $this |
75 | 75 | */ |
76 | - public function addMember (User $user) { |
|
76 | + public function addMember(User $user) { |
|
77 | 77 | return $this->addMembers([$user]); |
78 | 78 | } |
79 | 79 | |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | * @param User[] $users |
82 | 82 | * @return $this |
83 | 83 | */ |
84 | - public function addMembers (array $users) { |
|
84 | + public function addMembers(array $users) { |
|
85 | 85 | return $this->_addWithPost("{$this}/addMembers", [ |
86 | 86 | 'members' => array_column($users, 'gid') |
87 | 87 | ], 'members', $users); |
@@ -91,14 +91,14 @@ discard block |
||
91 | 91 | * @depends after-create |
92 | 92 | * @return Project[] |
93 | 93 | */ |
94 | - public function getItems () { |
|
94 | + public function getItems() { |
|
95 | 95 | return iterator_to_array($this); |
96 | 96 | } |
97 | 97 | |
98 | 98 | /** |
99 | 99 | * @return Traversable|Project[] |
100 | 100 | */ |
101 | - public function getIterator () { |
|
101 | + public function getIterator() { |
|
102 | 102 | return $this->api->loadEach($this, Project::class, "{$this}/items"); |
103 | 103 | } |
104 | 104 | |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | * @param Project $item |
108 | 108 | * @return $this |
109 | 109 | */ |
110 | - public function removeItem (Project $item) { |
|
110 | + public function removeItem(Project $item) { |
|
111 | 111 | $this->api->post("{$this}/removeItem", ['item' => $item->getGid()]); |
112 | 112 | return $this; |
113 | 113 | } |
@@ -116,7 +116,7 @@ discard block |
||
116 | 116 | * @param User $user |
117 | 117 | * @return $this |
118 | 118 | */ |
119 | - public function removeMember (User $user) { |
|
119 | + public function removeMember(User $user) { |
|
120 | 120 | return $this->removeMembers([$user]); |
121 | 121 | } |
122 | 122 | |
@@ -124,7 +124,7 @@ discard block |
||
124 | 124 | * @param User[] $users |
125 | 125 | * @return $this |
126 | 126 | */ |
127 | - public function removeMembers (array $users) { |
|
127 | + public function removeMembers(array $users) { |
|
128 | 128 | return $this->_removeWithPost("{$this}/removeMembers", [ |
129 | 129 | 'members' => array_column($users, 'gid') |
130 | 130 | ], 'members', $users); |
@@ -134,7 +134,7 @@ discard block |
||
134 | 134 | * @param callable $filter `fn( Project $project ): bool` |
135 | 135 | * @return Project[] |
136 | 136 | */ |
137 | - public function selectItems (callable $filter) { |
|
137 | + public function selectItems(callable $filter) { |
|
138 | 138 | return $this->_select($this, $filter); |
139 | 139 | } |
140 | 140 | } |
141 | 141 | \ No newline at end of file |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | * |
38 | 38 | * @return bool |
39 | 39 | */ |
40 | - final public function isActive (): bool { |
|
40 | + final public function isActive(): bool { |
|
41 | 41 | return $this->getState() === self::STATE_ACTIVE; |
42 | 42 | } |
43 | 43 | |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | * |
47 | 47 | * @return bool |
48 | 48 | */ |
49 | - final public function isDone (): bool { |
|
49 | + final public function isDone(): bool { |
|
50 | 50 | return $this->isSuccessful() or $this->isFailed(); |
51 | 51 | } |
52 | 52 | |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | * |
56 | 56 | * @return bool |
57 | 57 | */ |
58 | - final public function isFailed (): bool { |
|
58 | + final public function isFailed(): bool { |
|
59 | 59 | return $this->getState() === self::STATE_FAIL; |
60 | 60 | } |
61 | 61 | |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | * |
65 | 65 | * @return bool |
66 | 66 | */ |
67 | - final public function isQueued (): bool { |
|
67 | + final public function isQueued(): bool { |
|
68 | 68 | return $this->getState() === self::STATE_QUEUED; |
69 | 69 | } |
70 | 70 | |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | * |
74 | 74 | * @return bool |
75 | 75 | */ |
76 | - final public function isSuccessful (): bool { |
|
76 | + final public function isSuccessful(): bool { |
|
77 | 77 | return $this->getState() === self::STATE_SUCCESS; |
78 | 78 | } |
79 | 79 | |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | * @param callable $spinner `fn( OrganizationExport $this ): void` |
86 | 86 | * @return $this |
87 | 87 | */ |
88 | - public function wait (callable $spinner = null) { |
|
88 | + public function wait(callable $spinner = null) { |
|
89 | 89 | while (!$this->isDone()) { |
90 | 90 | if ($spinner) { |
91 | 91 | call_user_func($spinner, $this); |