Skip to content

Commit bf081e1

Browse files
Fixed #183: JSDOMNodeJSEnv is handled incorrectly (Scalajs support issue) (#212)
1 parent 2297d8c commit bf081e1

File tree

1 file changed

+3
-3
lines changed
  • scalac-scoverage-runtime/js/src/main/scala/scalajssupport

1 file changed

+3
-3
lines changed

scalac-scoverage-runtime/js/src/main/scala/scalajssupport/File.scala

+3-3
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,10 @@ object File {
6969

7070
val jsFile: JsFileObject = if (globalObject.hasOwnProperty("Packages").asInstanceOf[Boolean])
7171
RhinoFile
72-
else if (!globalObject.hasOwnProperty("window").asInstanceOf[Boolean])
73-
NodeFile
74-
else
72+
else if (globalObject.hasOwnProperty("callPhantom").asInstanceOf[Boolean])
7573
PhantomFile
74+
else
75+
NodeFile
7676
// Factorize this
7777

7878
def pathJoin(path: String, child: String): String =

0 commit comments

Comments
 (0)