Skip to content

Commit 5332dea

Browse files
committed
Don't convert nil to 0 when the given yyyymm was nil
1 parent 8f5e0b3 commit 5332dea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/controllers/messages_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ class MessagesController < ApplicationController
33

44
# GET /ruby-dev
55
def index(list_name: nil, yyyymm: nil, q: nil)
6-
yyyymm = yyyymm.to_i
6+
yyyymm = yyyymm&.to_i
77
if list_name
88
@list = List.find_by_name list_name
99

0 commit comments

Comments
 (0)