summaryrefslogtreecommitdiff
path: root/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc')
-rw-r--r--src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc b/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc
index dccf2e9fdd..9caf7e4c7a 100644
--- a/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc
+++ b/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/src/commands/mobile/delete_interaction_choice_set_request.cc
@@ -89,7 +89,13 @@ void DeleteInteractionChoiceSetRequest::Run() {
SendResponse(false, mobile_apis::Result::IN_USE);
return;
}
- SendVrDeleteCommand(app);
+ if (choice_set.keyExists(strings::grammar_id) &&
+ choice_set[strings::grammar_id].asInt() != -1) {
+ SendVrDeleteCommand(app);
+ } else {
+ response_result_codes_.push_back(hmi_apis::Common_Result::SUCCESS);
+ SendDeleteInteractionChoiceSetResponse();
+ }
}
bool DeleteInteractionChoiceSetRequest::Init() {