Skip to content

Commit ef6993e

Browse files
committed
IDBVersionChangeEvent.newVersion can be null
1 parent 5a502ad commit ef6993e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/main/scala/org/scalajs/dom/raw/Idb.scala

+4-2
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ class IDBObjectStore extends js.Object {
123123
}
124124

125125
trait IDBVersionChangeEventInit extends EventInit {
126-
var newVersion: js.UndefOr[Int] = js.undefined
126+
var newVersion: js.UndefOr[Integer] = js.undefined
127127
var oldVersion: js.UndefOr[Int] = js.undefined
128128
}
129129

@@ -142,9 +142,11 @@ class IDBVersionChangeEvent(typeArg: String,
142142
/**
143143
* Returns the new version of the database.
144144
*
145+
* This is null when the database is being deleted.
146+
*
145147
* MDN
146148
*/
147-
def newVersion: Int = js.native
149+
def newVersion: Integer = js.native
148150

149151
/**
150152
* Returns the old version of the database.

0 commit comments

Comments
 (0)