Skip to content

Commit

Permalink
refactor(freemobile): remove local throw
Browse files Browse the repository at this point in the history
  • Loading branch information
jef committed Apr 9, 2021
1 parent 6be2e0d commit bf8f242
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/notification/freemobile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ export function sendFreeMobileAlert(link: Link, store: Store) {
url.searchParams.append('msg', message);

try {
const response = await fetch(url.toString(), {
method: 'GET',
});
const response = await fetch(url.toString(), {method: 'GET'});

const http200Success = await response.ok;
if (!http200Success) throw Error(JSON.stringify(response));
if (!response.ok) {
logger.error("✖ couldn't send free mobile alert", response);
return;
}

logger.info('✔ free mobile alert sent');
} catch (error: unknown) {
Expand Down

0 comments on commit bf8f242

Please sign in to comment.