removeAllElementValues bug

Post your questions and help other users.

Moderator: Martin

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: removeAllElementValues bug

Post by Desmanto » 22 Jul 2019 17:19

Can confirm the bug. It is the fromJSON(), because toJSON() convert list/map to text. Using

Code: Select all

map = fromJSON('{"1":1,"2":2,"3":3,"4":4}');
list1=getMapValues(map);
list2=newList(1,2,3,4);
diff=removeAllElementValues(list1, list2);
Also make the diff not empty.

I am so afraid about this and immediately check most of my init text and use fromJSON() flow. Fortunately I don't use removeAllElementValues(), only loop with removeElementValue() on all list/map created fromJSON(). Maybe this is why I don't encounter this problem.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: removeAllElementValues bug

Post by Martin » 23 Jul 2019 12:41

Thanks for reporting! This is fixed in the next build.

Regards,
Martin

anuraag
Posts: 371
Joined: 24 Jan 2015 02:06

Re: removeAllElementValues bug

Post by anuraag » 26 Jul 2019 03:52

Tested. Fixed in latest EAP.

Post Reply