Fix wrong parameter order in Team#team_member_by_name_or_email
This commit is contained in:
parent
51ef5b9297
commit
b3a5f0a78d
1 changed files with 3 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
||||||
module Team
|
module Team
|
||||||
def team_member_by_name_or_email(email = nil, name = nil)
|
def team_member_by_name_or_email(name = nil, email = nil)
|
||||||
user = users.where("email like ? or name like ?", email, name).first
|
user = users.where("name like ? or email like ?", name, email).first
|
||||||
users_projects.find_by_user_id(user.id) if user
|
users_projects.where(user: user) if user
|
||||||
end
|
end
|
||||||
|
|
||||||
# Get Team Member record by user id
|
# Get Team Member record by user id
|
||||||
|
|
Loading…
Reference in a new issue