fix example code in engines guide

this is a fix for issue #8583

I added a new section to explain the change we need to make to the association definition after we changed `user_class` from returning a `String` to returning a `Class`.

Also the guide contained trailing whitespace which I removed.