File tree Expand file tree Collapse file tree
java/com/runtracker/global/fcm Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -29,11 +29,9 @@ public void initialize() {
2929 new java .io .ByteArrayInputStream (firebaseJson .getBytes ())
3030 );
3131 } else if (serviceAccountKeyPath != null && !serviceAccountKeyPath .isEmpty ()) {
32- String resourcePath = serviceAccountKeyPath .startsWith ("classpath:" )
33- ? serviceAccountKeyPath .substring (10 )
34- : serviceAccountKeyPath ;
32+ String firebasePath = "firebase/" + serviceAccountKeyPath ;
3533 googleCredentials = GoogleCredentials
36- .fromStream (new ClassPathResource (resourcePath ).getInputStream ());
34+ .fromStream (new ClassPathResource (firebasePath ).getInputStream ());
3735 } else {
3836 throw new RuntimeException ("Firebase service account key not found. Please set FCM_JSON or FIREBASE_SERVICE_ACCOUNT_KEY" );
3937 }
Original file line number Diff line number Diff line change 6767 key : ${AUTH_KEY}
6868
6969firebase :
70- service-account-key : classpath:firebase/ ${FIREBASE_SERVICE_ACCOUNT_KEY:}
70+ service-account-key : ${FIREBASE_SERVICE_ACCOUNT_KEY:}
7171 url : https://fcm.googleapis.com/v1/projects/${Firebase_ID}/messages:send
7272 google_api : https://www.googleapis.com/auth/cloud-platform
7373 project_id : ${Firebase_ID}
You can’t perform that action at this time.
0 commit comments