if(Integer.toString(f.getId().equalsIgnoreCase(id)) &&
You are converting some value (returned from
f.getId
) to a string, and then trying to compare it with an integer value (
id
). But that makes no sense, you cannot compare a string with an integer. But why are you converting a value to a string in order to compare it? Why not just write:
if(f.getId() == id) &&
Also you have tagged this question Javascript, but I am reasonably sure it is Java.