Skip to content

Commit 4676113

Browse files
committed
improve linux browser detection
1 parent ad1beea commit 4676113

File tree

1 file changed

+2
-0
lines changed
  • examples/official-site/your-first-sql-website

1 file changed

+2
-0
lines changed

examples/official-site/your-first-sql-website/index.sql

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ select 'dynamic' as component, properties FROM example WHERE component = 'shell'
77
set os = COALESCE($os, case
88
when sqlpage.header('user-agent') like '%windows%' then 'windows'
99
when sqlpage.header('user-agent') like '%x11; linux%' then 'linux'
10+
when sqlpage.header('user-agent') like '%x11; ubuntu; linux%' then 'linux'
11+
when sqlpage.header('user-agent') like '%x11; debian; linux%' then 'linux'
1012
when sqlpage.header('user-agent') like '%macintosh%' then 'macos'
1113
else 'any'
1214
end);

0 commit comments

Comments
 (0)