Skip to content

Commit df14215

Browse files
committed
MERGE: Merge branch '2.0' into 3.0
2 parents 69fc9aa + f3a8585 commit df14215

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

Classes/Command/NodeIndexCommandController.php

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,12 @@ public function indexNodeCommand($identifier, $workspace = null)
181181
$indexInWorkspace($identifier, $workspace);
182182
}
183183
} else {
184-
$workspace = $this->workspaceRepository->findByIdentifier($workspace);
185-
$indexInWorkspace($identifier, $workspace);
184+
$workspaceInstance = $this->workspaceRepository->findByIdentifier($workspace);
185+
if ($workspaceInstance === null) {
186+
$this->outputLine('The given workspace (%s) does not exist.', [$workspace]);
187+
$this->quit(1);
188+
}
189+
$indexInWorkspace($identifier, $workspaceInstance);
186190
}
187191
}
188192

@@ -199,6 +203,11 @@ public function indexNodeCommand($identifier, $workspace = null)
199203
*/
200204
public function buildCommand($limit = null, $update = false, $workspace = null, $postfix = null)
201205
{
206+
if ($workspace !== null && $this->workspaceRepository->findByIdentifier($workspace) === null) {
207+
$this->logger->log('The given workspace (' . $workspace . ') does not exist.', LOG_ERR);
208+
$this->quit(1);
209+
}
210+
202211
if ($update === true) {
203212
$this->logger->log('!!! Update Mode (Development) active!', LOG_INFO);
204213
} else {

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ prototype(Vendor.Name:FilteredProductList) {
293293
```
294294

295295
In the first lines we will add a new searchFilter variable and add your selected sku's as a filter. Based on this selection
296-
we will add two aggregations of type terms. You can access the filter in your template with `{filter.aggregation}`. With
296+
we will add two aggregations of type terms. You can access the filter in your template with `{filter.aggregations}`. With
297297
this information it is easy to create a form with some select fields with all available options. If you submit the form
298298
just call the same page and add the get parameter color and/or size.
299299
The next lines will parse those parameters and add them to the searchFilter. Based on your selection all products will

0 commit comments

Comments
 (0)