Changed Eloquent functionality to trait