Skip to content

Commit

Permalink
Merge pull request #109 from podigee/fg/fix-empty-user-agent-bug
Browse files Browse the repository at this point in the history
Avoid error when user agent is nil

fixes #104
  • Loading branch information
spiderpug authored Aug 3, 2023
2 parents 3acf2a8 + bf4de1d commit 97dc220
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/device_detector.rb
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ def linux_fix?

# Related to issue mentionned in device.rb#1562
def fix_for_x_music
user_agent.include?('X-music Ⅲ') ? 'X-Music III' : nil
user_agent&.include?('X-music Ⅲ') ? 'X-Music III' : nil
end

def skip_os_version?
Expand Down

0 comments on commit 97dc220

Please sign in to comment.