Adriano Faria Posted April 13 Share Posted April 13 You are using a hard-coded column name: /** * Get the database column which stores the topic ID * * @return string */ public static function topicIdColumn() { return 'topicid'; } Can't you use a mapped column from the model to avoid changing files and templates? That happens in apps that uses topics released before the trait. Link to comment Share on other sites More sharing options...
Solution Ryan Ashbrook Posted April 13 Solution Share Posted April 13 Classes using the trait can overload the method if the column name does not match - in this case, the trait is simply providing a default value. Using mapped() would not work, because the "topic" column isn't actually included in the $databaseColumnMap property. Adriano Faria 1 Link to comment Share on other sites More sharing options...
Recommended Posts