Database error - additional info fields - add/delete
Brought to you by:
bro3,
mediterranean
ArrayIndexOutOfBoundsException occurs after adding and
deleting a new additional info field before saving.
New movies can not be added, or existing be edited.
Can be "fixed" by clearing the value in the
"Settings"."Active Additional Info Field" column in
the database.
Logged In: YES
user_id=1642919
Hi :
I think i solved this one, when you remove an item ,it is
removed from the array _toRemove, but it is not removed from
the DefaultListModel, we have to add a line to remove it and
its done, this is the fixed executeCommandRemove() :
P.D : ive never "worked" in a sourceforge project, so i dont
know what i must do, i mean, its ok to post the fix here?
maybe you have fixed it? how can i know if someone is
working in a bug or in a feature request?
private void executeCommandRemove() {
(String)((DefaultListModel)getActiveFields().getModel()).getElementAt(selectedIndex);
/* Removes the field from the add list... */
if(_toAdd.contains(field)) {
_toAdd.remove(field);
((DefaultListModel)getActiveFields().getModel()).remove(selectedIndex);/*LINE
ADDED*/
}
the original... */
if(!_toRemove.contains(field) &&
_originalExtraList.contains(field)) {
_toRemove.add(field);
((DefaultListModel)getActiveFields().getModel()).remove(selectedIndex);
((DefaultListModel)getActiveFields().getModel()).size())
getActiveFields().setSelectedIndex(--selectedIndex);
else
getActiveFields().setSelectedIndex(selectedIndex);
}
Logged In: YES
user_id=840074
Originator: YES
Hi
Sorry I didn't reply but the email notice was sent to the spam folder...darn.
This bug is fixed in CVS.
Bro
Logged In: YES
user_id=921651
Originator: NO
Has been worked over in 2.5.2 and should now be fixed. Please test extensively :-)
Matthias