Topic: Named associations with inverse_of

Hi all,
I have 3 models: User, Ticket and Location

In the user and ticket models, I have:

has_many :tickets, inverse_of: user
belongs_to :user, inverse_of :user

Which works fine:

User.first.object_id => 70199814094580 => 70199814094580

However, the user->location model is a little more complicated. Depending on the users' role, the name of the association that the controllers call is different.

A user is assigned a location (belongs_to), but they also manage locations (has_many).
This means I have these associations in the user model:

has_many :locations, through: :location_directories #note not using inverse_of here due to hmt
belongs_to :location, primary_key: 'id', foreign_key: 'assigned_to_location_id', class_name: 'Location', inverse_of: :manager

and in the Location model...

has_one :manager, foreign_key: 'assigned_to_location_id', class_name: 'User', inverse_of: :location

But testing this out gives me different object id's for the instances of the models:

User.first.object_id => 70199814094580
User.first.location.users.find{|u| u.user_id ==}.object_id => _some_other_id_
User.first.location.users[0].object_id => _some_other_id_ 

Any idea's if rails supports inverse_of on named associations? I couldn't find any docs that say it doesn't (only has_many :through, and :polymorphic aren't supported).

help! smile

thanks for reading.