Skip to content

Commit

Permalink
#28 #29 again minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Plugsocket committed Dec 9, 2018
1 parent f0472e2 commit a1c0225
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ public boolean canHandle(HandlerInput input) {
return input.matches(intentName("SelectRecipeByCategoryIntent"));
}

@Override
@SuppressWarnings("null")
@Override
public Optional<Response> handle(HandlerInput input) {
String speechText;
Request request = input.getRequestEnvelope().getRequest();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public Optional<Response> handle(HandlerInput input) {
recipe.setNumberOfPeople(6);
recipe.changeIngredientAmounts();
}
speechText = "Dein Rezept ist nun fuer" + actualNumber + "ausgerichtet";
speechText = String.format(PhrasesForAlexa.PEOPLE_SET, actualNumber);
}

return input.getResponseBuilder()
Expand Down
1 change: 1 addition & 0 deletions src/main/java/verkocht/model/PhrasesForAlexa.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ private PhrasesForAlexa() {

//Number of People
public static final String PEOPLE_UNKNOWN = "Ich habe die Anzahl der Personen leider nicht genau verstanden, sage zum Beispiel: Ich moechte fuer zwei Personen kochen";
public static final String PEOPLE_SET = "Dein Rezept ist nun fuer %s ausgerichtet";

// Cancel-/Stop-/Help-/Fallback-Intent
public static final String SORRY = "Tut mir leid, das weiss ich nicht. Sage einfach Hilfe.";
Expand Down

0 comments on commit a1c0225

Please sign in to comment.