Skip to content

Commit c415df3

Browse files
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent ad64a9b commit c415df3

1 file changed

Lines changed: 2 additions & 6 deletions

File tree

games/Emoji-Memory-Game/Emoji-Memory-Game.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,8 @@
2424

2525
# Detect if running in browser (Pyodide)
2626
def is_browser():
27-
"""Return True if running in browser environment (Pyodide)."""
28-
try:
29-
import js # Pyodide exposes this global
30-
return True
31-
except ImportError:
32-
return False
27+
"""Return True if running in a browser environment (Pyodide)."""
28+
return sys.platform == "emscripten"
3329

3430

3531
# Core, testable logic (no I/O, no global state)

0 commit comments

Comments
 (0)