Code for http://robertclancy.net/blog/2-repository-design-pattern-in-laravel-4