mirror of
https://github.com/KDE/kdeconnect-android
synced 2025-08-30 21:55:10 +00:00
Use stringbuilder
This commit is contained in:
@@ -233,16 +233,11 @@ public class TelephonyPlugin extends Plugin {
|
|||||||
|
|
||||||
np.set("event","sms");
|
np.set("event","sms");
|
||||||
|
|
||||||
String messageBody = new String();
|
StringBuilder messageBody = new StringBuilder();
|
||||||
|
for (int index = 0; index < messages.size(); index ++) {
|
||||||
for (int index = 0; index < messages.size(); index ++)
|
messageBody.append(messages.get(index).getMessageBody());
|
||||||
{
|
|
||||||
messageBody += messages.get(index).getMessageBody();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (messageBody != null) {
|
|
||||||
np.set("messageBody",messageBody);
|
|
||||||
}
|
}
|
||||||
|
np.set("messageBody", messageBody.toString());
|
||||||
|
|
||||||
String phoneNumber = messages.get(0).getOriginatingAddress();
|
String phoneNumber = messages.get(0).getOriginatingAddress();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user