Description: - HasOne docs problem.
just check RC1 docs (not online docs) even when applies since 4.1 beta.
hasOne docs are describing the same thing as a belongsTo association. check the docs for both associations and ull see they are describing the same thing.
hasOne is not the same as belongsTo.
hasOne rc1 docs says "The owner model is expected to have a foreign key which references the primary key of the associated model"
and should say "The associated model is expected to have a foreign key which references the primary key of the owner model"
if this needs more detailed explanation just tell and ill explain but i think anyone that knows bout associations will understand this.
their diference is "where the foreign key is placed".
and anyway current hasOne is describing the same as belongsTo so if that were correct not point to have a hasOne association.
this correction is important because helps to understand what its implemented.
- hasOne source code problem
setter is doing the same thing as belongsTo does, i guess because is trying to implement what docs says, but after you check docs are wrong then the implementation needs to change.