Skip to content

Commit

Permalink
Merge pull request #115 from casperisfine/default-port
Browse files Browse the repository at this point in the history
Ruby: Better handle `port: nil`
  • Loading branch information
adrianna-chang-shopify authored Aug 18, 2023
2 parents 5678822 + 9cae759 commit d0ef008
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contrib/ruby/lib/trilogy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

class Trilogy
def initialize(options = {})
options[:port] = options[:port].to_i if options.key?(:port)
options[:port] = options[:port].to_i if options[:port]
mysql_encoding = options[:encoding] || "utf8mb4"
encoding = Trilogy::Encoding.find(mysql_encoding)
charset = Trilogy::Encoding.charset(mysql_encoding)
Expand Down

0 comments on commit d0ef008

Please sign in to comment.