fix after the template object is received with a mongo _id instead of simply id