Created
October 18, 2020 16:19
-
-
Save theawesomenayak/0c069910f066e7544d6e2c8419edcf5f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try { | |
final String output = getNewsFromGoogle(); | |
return response.withStatusCode(200).withBody(output); | |
} catch (final IOException | InterruptedException | XMLStreamException e) { | |
return response.withBody("{}").withStatusCode(500); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment