Further improved text of some error messages
This commit is contained in:
parent
ec5ff5f230
commit
42f37d8fee
2 changed files with 5 additions and 5 deletions
|
@ -18,10 +18,10 @@ class SnapshotSearchParser extends AbstractSearchParser
|
||||||
protected function decorateFilterFromToken(IFilter $filter, SearchToken $token)
|
protected function decorateFilterFromToken(IFilter $filter, SearchToken $token)
|
||||||
{
|
{
|
||||||
if (substr_count($token->getValue(), ',') !== 1)
|
if (substr_count($token->getValue(), ',') !== 1)
|
||||||
throw new NotSupportedException();
|
throw new NotSupportedException('Expected token in form of "type,id"');
|
||||||
|
|
||||||
if ($token->isNegated())
|
if ($token->isNegated())
|
||||||
throw new NotSupportedException();
|
throw new NotSupportedException('Negative searches are not supported in this context');
|
||||||
|
|
||||||
list ($type, $primaryKey) = explode(',', $token->getValue());
|
list ($type, $primaryKey) = explode(',', $token->getValue());
|
||||||
|
|
||||||
|
@ -38,11 +38,11 @@ class SnapshotSearchParser extends AbstractSearchParser
|
||||||
|
|
||||||
protected function decorateFilterFromNamedToken(IFilter $filter, NamedSearchToken $namedToken)
|
protected function decorateFilterFromNamedToken(IFilter $filter, NamedSearchToken $namedToken)
|
||||||
{
|
{
|
||||||
throw new NotSupportedException();
|
throw new NotSupportedException('Named tokens are not supported in this context');
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getOrderColumnMap()
|
protected function getOrderColumnMap()
|
||||||
{
|
{
|
||||||
throw new NotSupportedException();
|
throw new NotSupportedException('Search order is not supported in this context');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ class TagSearchParser extends AbstractSearchParser
|
||||||
self::ALLOW_COMPOSITE);
|
self::ALLOW_COMPOSITE);
|
||||||
}
|
}
|
||||||
|
|
||||||
throw new NotSupportedException();
|
throw new NotSupportedException('Unknown token: ' . $namedToken->getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getOrderColumnMap()
|
protected function getOrderColumnMap()
|
||||||
|
|
Loading…
Reference in a new issue