Skip to content

Commit 52b9ac5

Browse files
committed
reduce unnecessary check on id
1 parent bd9bb2a commit 52b9ac5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/active_hash/base.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ def []=(key, val)
447447
end
448448

449449
def id
450-
attributes[:id] ? attributes[:id] : nil
450+
attributes[:id]
451451
end
452452

453453
def id=(id)

0 commit comments

Comments
 (0)