mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 08:22:41 +08:00

The model classes encapsulate knowledge about the database that may change. That knowledge may be table names, or the value of constants (such as `Group::MEMBER_ID` in this case). Models may even disappear after a while due to refactorings. In all these cases, this migration would break. Thus, we use Laravel's query builder features which makes building queries almost as easy as using the model - but correct in all cases. :-)