So, I have this block of code, and yes it looks ugly. Is there a better a data structure I can use to compare row.add,row.modify,row.delete and row.query with "Y" and call the get_role function? Note this block of code runs in a loop, hence the 'row'.
if row.add == "y"
role_ids << get_role("c")
end
if row.modify == "y"
role_ids << get_role("u")
end
if row.delete == "y"
role_ids << get_role("d")
end
if row.query == "y"
role_ids << get_role("r")
end
Thanks !