Fixed bug when trying to add multiple attachment types to the same model.