2021-02-16から1日間の記事一覧
sidekiq logger prints messages with occurrence time. This time is UTC. I wanted to use JST. After investigating the source code and github of sideq, I retired to do that. Because I realized sidekiq uses only UTC arbitrarily. In sidekiq log…
As you know break terminates loop. Below code execute the block only once. And return nil. [1, 2, 3].each { |n| break } # => nil break can have 1 argument. If the argument was given, the value will be used as the return value of evaluation…
We can authenticate an user with twitter. Set route as below. This activates callback url from twitter. devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" } devise_scope :user do get 'sign_in', :to => 'd…