Skip to content

Commit

Permalink
continue to pass null if param is not set
Browse files Browse the repository at this point in the history
  • Loading branch information
jay-hodgson committed Oct 15, 2024
1 parent c4cdd47 commit 46aabe0
Showing 1 changed file with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@ public void start(AcceptsOneWidget panel, EventBus eventBus) {
public void setPlace(ChatPlace place) {
this.place = place;
// SWC-7109: Decode place parameters
String initialMessage = gwt.decodeQueryString(
place.getParam(ChatPlace.INITIAL_MESSAGE)
);
String initialMessage = place.getParam(ChatPlace.INITIAL_MESSAGE);
if (initialMessage != null) {
initialMessage = gwt.decodeQueryString(initialMessage);
}
String agentId = place.getParam(ChatPlace.AGENT_ID);
String chatbotName = gwt.decodeQueryString(
place.getParam(ChatPlace.CHATBOT_NAME)
);
String chatbotName = place.getParam(ChatPlace.CHATBOT_NAME);
if (chatbotName != null) {
chatbotName = gwt.decodeQueryString(chatbotName);
}

view.render(initialMessage, agentId, chatbotName);
}
Expand Down

0 comments on commit 46aabe0

Please sign in to comment.