Skip to content

Commit

Permalink
improved wording
Browse files Browse the repository at this point in the history
  • Loading branch information
dayjaby committed Jan 29, 2022
1 parent 8a89e76 commit 4bc0d91
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pb_plugins/protoc_gen_mavsdk/methods.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def extract_return_type_and_name(self, pb_method, responses):
if len(return_params) > 1:
raise Exception(
"Responses cannot have more than 1 return parameter" +
f"(and an optional '*Result')!\nError in {method_output}")
f" (and an optional '*Result')!\nError in {method_output}")

if len(return_params) == 1:
self._return_type = type_info_factory.create(
Expand All @@ -76,8 +76,8 @@ def extract_return_type_and_name(self, pb_method, responses):
self._return_description = return_params[0]['docs']
elif len(return_params) == 0 and self.return_type_required:
raise Exception(
"Responses must have 1 return parameter" +
f"(and an optional '*Result')!\nError in {method_output}")
"This response must have 1 return parameter" +
f" (and an optional '*Result')!\nError in {method_output}")

def extract_async_type(self, pb_method):
self._is_sync = True
Expand Down

0 comments on commit 4bc0d91

Please sign in to comment.