Skip to content
Snippets Groups Projects
Unverified Commit 0262f97b authored by Siraj R Aizlewood's avatar Siraj R Aizlewood
Browse files

Linting.

parent 25eae243
No related branches found
No related tags found
No related merge requests found
......@@ -230,7 +230,7 @@ class RouteLayer:
route, top_class_scores = self._retrieve_top_route(vector)
passed = self._check_threshold(top_class_scores, route)
if passed:
if passed and route is not None:
if route.function_schema and text is None:
raise ValueError(
"Route has a function schema, but no text was provided."
......@@ -512,7 +512,7 @@ class RouteLayer:
"""
route, scores = self._retrieve_top_route(vector)
passed = self._check_threshold(scores, route)
if passed:
if passed and route is not None:
return RouteChoice(
name=route.name, function_call=None, similarity_score=None, trigger=None
)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment