Skip to content

Commit cb27831

Browse files
committed
UserFieldType should grab the @user_id, not @id, during verification of User ID
1 parent a64b712 commit cb27831

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

app/models/user_field_type.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ def mapping_field_name
2525
end
2626

2727
def valid_user_id?
28-
return true if id.nil?
28+
return true if user_id.nil?
2929

30-
unless User.exists?(id)
31-
errors.add(:user_id, "Must be for a Valid User")
30+
unless User.exists?(user_id)
31+
errors.add(:user_id, "does not exist")
3232
false
3333
end
3434
end

0 commit comments

Comments
 (0)