Adding callback to model