An implementation of the repository pattern in laravel