Skip to content

Remove inappropriate IDBKeyRange usages from lib.dom.d.ts. #630

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 24, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions baselines/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8691,12 +8691,12 @@ interface IDBCursor {
* Returns the key of the cursor.
* Throws a "InvalidStateError" DOMException if the cursor is advancing or is finished.
*/
readonly key: IDBValidKey | IDBKeyRange;
readonly key: IDBValidKey;
/**
* Returns the effective key of the cursor.
* Throws a "InvalidStateError" DOMException if the cursor is advancing or is finished.
*/
readonly primaryKey: IDBValidKey | IDBKeyRange;
readonly primaryKey: IDBValidKey;
/**
* Returns the IDBObjectStore or IDBIndex the cursor was opened from.
*/
Expand All @@ -8710,12 +8710,12 @@ interface IDBCursor {
* Advances the cursor to the next record in range matching or
* after key.
*/
continue(key?: IDBValidKey | IDBKeyRange): void;
continue(key?: IDBValidKey): void;
/**
* Advances the cursor to the next record in range matching
* or after key and primaryKey. Throws an "InvalidAccessError" DOMException if the source is not an index.
*/
continuePrimaryKey(key: IDBValidKey | IDBKeyRange, primaryKey: IDBValidKey | IDBKeyRange): void;
continuePrimaryKey(key: IDBValidKey, primaryKey: IDBValidKey): void;
/**
* Delete the record pointed at by the cursor with a new value.
* If successful, request's result will be undefined.
Expand Down Expand Up @@ -8964,7 +8964,7 @@ interface IDBObjectStore {
* Returns the associated transaction.
*/
readonly transaction: IDBTransaction;
add(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>;
add(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>;
/**
* Deletes all records in store.
* If successful, request's result will
Expand Down Expand Up @@ -9037,7 +9037,7 @@ interface IDBObjectStore {
* null if there were no matching records.
*/
openKeyCursor(query?: IDBValidKey | IDBKeyRange, direction?: IDBCursorDirection): IDBRequest<IDBCursor | null>;
put(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>;
put(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>;
}

declare var IDBObjectStore: {
Expand Down
12 changes: 6 additions & 6 deletions baselines/webworker.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1394,12 +1394,12 @@ interface IDBCursor {
* Returns the key of the cursor.
* Throws a "InvalidStateError" DOMException if the cursor is advancing or is finished.
*/
readonly key: IDBValidKey | IDBKeyRange;
readonly key: IDBValidKey;
/**
* Returns the effective key of the cursor.
* Throws a "InvalidStateError" DOMException if the cursor is advancing or is finished.
*/
readonly primaryKey: IDBValidKey | IDBKeyRange;
readonly primaryKey: IDBValidKey;
/**
* Returns the IDBObjectStore or IDBIndex the cursor was opened from.
*/
Expand All @@ -1413,12 +1413,12 @@ interface IDBCursor {
* Advances the cursor to the next record in range matching or
* after key.
*/
continue(key?: IDBValidKey | IDBKeyRange): void;
continue(key?: IDBValidKey): void;
/**
* Advances the cursor to the next record in range matching
* or after key and primaryKey. Throws an "InvalidAccessError" DOMException if the source is not an index.
*/
continuePrimaryKey(key: IDBValidKey | IDBKeyRange, primaryKey: IDBValidKey | IDBKeyRange): void;
continuePrimaryKey(key: IDBValidKey, primaryKey: IDBValidKey): void;
/**
* Delete the record pointed at by the cursor with a new value.
* If successful, request's result will be undefined.
Expand Down Expand Up @@ -1663,7 +1663,7 @@ interface IDBObjectStore {
* Returns the associated transaction.
*/
readonly transaction: IDBTransaction;
add(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>;
add(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>;
/**
* Deletes all records in store.
* If successful, request's result will
Expand Down Expand Up @@ -1736,7 +1736,7 @@ interface IDBObjectStore {
* null if there were no matching records.
*/
openKeyCursor(query?: IDBValidKey | IDBKeyRange, direction?: IDBCursorDirection): IDBRequest<IDBCursor | null>;
put(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>;
put(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>;
}

declare var IDBObjectStore: {
Expand Down
12 changes: 6 additions & 6 deletions inputfiles/overridingTypes.json
Original file line number Diff line number Diff line change
Expand Up @@ -697,7 +697,7 @@
"add": {
"name": "add",
"override-signatures": [
"add(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>"
"add(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>"
]
},
"clear": {
Expand All @@ -721,7 +721,7 @@
"put": {
"name": "put",
"override-signatures": [
"put(value: any, key?: IDBValidKey | IDBKeyRange): IDBRequest<IDBValidKey>"
"put(value: any, key?: IDBValidKey): IDBRequest<IDBValidKey>"
]
},
"get": {
Expand Down Expand Up @@ -1254,11 +1254,11 @@
"property": {
"key": {
"name": "key",
"override-type": "IDBValidKey | IDBKeyRange"
"override-type": "IDBValidKey"
},
"primaryKey": {
"name": "primaryKey",
"override-type": "IDBValidKey | IDBKeyRange"
"override-type": "IDBValidKey"
}
}
},
Expand All @@ -1267,13 +1267,13 @@
"continue": {
"name": "continue",
"override-signatures": [
"continue(key?: IDBValidKey | IDBKeyRange): void"
"continue(key?: IDBValidKey): void"
]
},
"continuePrimaryKey": {
"name": "continuePrimaryKey",
"override-signatures": [
"continuePrimaryKey(key: IDBValidKey | IDBKeyRange, primaryKey: IDBValidKey | IDBKeyRange): void"
"continuePrimaryKey(key: IDBValidKey, primaryKey: IDBValidKey): void"
]
},
"delete": {
Expand Down