It is throwing exception, while reading the message.
If message doesn't have the hash. This plugin reads the message and sends a null message with status as success, which further throws an exception NullPointerException: Println needs a message at the following line.
Log.d(TAG, message);
case CommonStatusCodes.SUCCESS:
final String message = extra.getString(SmsRetriever.EXTRA_SMS_MESSAGE);
//if (!StringUtils.hasContent(message)) return;
Log.d(TAG, message);
data = new JSONObject();
try {
data.put("Message",message);
} catch(JSONException e) {}
//Toast.makeText(cordova.getActivity().getApplicationContext(),"Message: "+ message, Toast.LENGTH_LONG).show();
PluginResult result = new PluginResult(PluginResult.Status.OK, data);
callbackContext.sendPluginResult(result);
break;
It is throwing exception, while reading the message. If message doesn't have the hash. This plugin reads the message and sends a null message with status as success, which further throws an exception NullPointerException: Println needs a message at the following line.
Log.d(TAG, message);