cast to (Object[])

This commit is contained in:
Vojtech Novak
2018-07-24 16:01:16 +02:00
committed by GitHub
parent 109f8309cf
commit 28dfbdf253

View File

@@ -323,7 +323,7 @@ public class RNFirebaseNotifications extends ReactContextBaseJavaModule implemen
String[] titleLocArgs = notification.getTitleLocalizationArgs();
Context ctx = getReactApplicationContext();
int resId = getResId(ctx, titleLocKey);
return ctx.getResources().getString(resId, titleLocArgs);
return ctx.getResources().getString(resId, (Object[]) titleLocArgs);
} else {
return null;
}
@@ -337,7 +337,7 @@ public class RNFirebaseNotifications extends ReactContextBaseJavaModule implemen
String[] bodyLocArgs = notification.getBodyLocalizationArgs();
Context ctx = getReactApplicationContext();
int resId = getResId(ctx, bodyLocKey);
return ctx.getResources().getString(resId, bodyLocArgs);
return ctx.getResources().getString(resId, (Object[]) bodyLocArgs);
} else {
return null;
}