File tree Expand file tree Collapse file tree
autoendpoint/src/routers/fcm Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -159,10 +159,12 @@ impl FcmClient {
159159 . await
160160 . map_err ( FcmError :: DeserializeResponse ) ?;
161161 if raw_data. is_empty ( ) {
162+ warn ! ( "Empty GCM response [{status}]" ) ;
162163 return Err ( FcmError :: EmptyResponse ( status) . into ( ) ) ;
163164 }
164165 let data: GcmResponse = serde_json:: from_slice ( & raw_data) . map_err ( |e| {
165166 let s = String :: from_utf8 ( raw_data. to_vec ( ) ) . unwrap_or_else ( |e| e. to_string ( ) ) ;
167+ warn ! ( "Invalid GCM response [{status}], \" {s}\" " ) ;
166168 FcmError :: InvalidResponse ( e, s, status)
167169 } ) ?;
168170
@@ -251,10 +253,12 @@ impl FcmClient {
251253 . await
252254 . map_err ( FcmError :: DeserializeResponse ) ?;
253255 if raw_data. is_empty ( ) {
256+ warn ! ( "Empty FCM response [{status}]" ) ;
254257 return Err ( FcmError :: EmptyResponse ( status) . into ( ) ) ;
255258 }
256259 let data: FcmResponse = serde_json:: from_slice ( & raw_data) . map_err ( |e| {
257260 let s = String :: from_utf8 ( raw_data. to_vec ( ) ) . unwrap_or_else ( |e| e. to_string ( ) ) ;
261+ warn ! ( "Invalid FCM response [{status}] \" {s}\" " ) ;
258262 FcmError :: InvalidResponse ( e, s, status)
259263 } ) ?;
260264
You can’t perform that action at this time.
0 commit comments