laravel/framework — pull request #4877 by FractalizeR (2014-06-28 13:24:41+00:00)
Title: A fix for #4498 and #4684. Eloquent model now boots all used traits, not only those declared in current class only

A fix for #4498 and #4684.

As described in #4498, if you add a trait to a parent model any children models will include the properties and methods of that trait but it's boot method will not be called. This is because Eloquent only boots the traits of the model itself, not it's parent models.

This patch introduces a new helper for deep traits inspection + modifies Eloquent model to use this helper instead of ```class_uses()```