File tree Expand file tree Collapse file tree 3 files changed +14
-3
lines changed Expand file tree Collapse file tree 3 files changed +14
-3
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " italia-backend" ,
3
- "version" : " 0.3.3 " ,
3
+ "version" : " 0.3.4 " ,
4
4
"description" : " Italia app and web backend" ,
5
5
"main" : " index.js" ,
6
6
"engines" : {
137
137
" !src/**/*.d.ts"
138
138
]
139
139
}
140
- }
140
+ }
Original file line number Diff line number Diff line change @@ -45,8 +45,11 @@ export default class NotificationController {
45
45
const errorOrUser = extractUserFromRequest ( req ) ;
46
46
47
47
if ( isLeft ( errorOrUser ) ) {
48
- // Unable to extract the user from the request.
49
48
const error = errorOrUser . value ;
49
+ log . error (
50
+ "Unable to extract the user from the request: %s" ,
51
+ error . message
52
+ ) ;
50
53
return ResponseErrorInternal ( error . message ) ;
51
54
}
52
55
Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ import {
22
22
INotificationTemplate ,
23
23
toFiscalCodeHash
24
24
} from "../types/notification" ;
25
+ import { log } from "../utils/logger" ;
25
26
26
27
/**
27
28
* A template suitable for Apple's APNs.
@@ -105,6 +106,13 @@ export default class NotificationService {
105
106
// tslint:disable-next-line:no-any
106
107
( azureInstallation as any ) as string ,
107
108
( error , response ) => {
109
+ if ( error ) {
110
+ log . error (
111
+ "Unable to create installation: %s (error=%s)" ,
112
+ JSON . stringify ( azureInstallation ) ,
113
+ error . message
114
+ ) ;
115
+ }
108
116
return resolve ( this . buildResponse ( error , response ) ) ;
109
117
}
110
118
) ;
You can’t perform that action at this time.
0 commit comments