I have a model called Application with construct() method inside it and i add $fillable to my model. I know that i should not use Application::create() for mass assignment and use new Application instead but my question is why i am getting null result from eloquent first() when i call eloquent search with where()?
here is my model
protected $guarded = ['id'];
protected $fillable = ['size','status','packagename','title','type','version','port','mouse','keyboard','game','cms_user_id','url'];
public function __construct( $value = NULL, array $attributes = array() )
{
parent::__construct($attributes);
}
and i have this line in my controller returns null
$application = Application::where('packagename',$request->packagename)->first();