Fix wrong id being used in forms