KamWithK / AnkiconnectAndroid

Unofficial Ankiconnect for Android (i.e. for Yomichan)
GNU General Public License v3.0
98 stars 14 forks source link

Fix updateNoteFields ArrayIndexOutOfBoundsException #65

Open ZXY101 opened 1 month ago

ZXY101 commented 1 month ago

https://github.com/KamWithK/AnkiconnectAndroid/pull/52 Bumped Anki-Android to 2.17alpha14 which effected the getFields call.

Ankidroid now removes the fields at the end of the array if they're empty, see here

So originalFields would occasionally have less fields than modelFieldNames and it would throw a ArrayIndexOutOfBoundsException.