Fixed a bug regarding the models