File tree Expand file tree Collapse file tree 5 files changed +7
-8
lines changed Expand file tree Collapse file tree 5 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " testcafe-hammerhead" ,
3
3
"description" : " A powerful web-proxy used as a core for the TestCafe testing framework (https://github.com/DevExpress/testcafe)." ,
4
- "version" : " 31.4.13 " ,
4
+ "version" : " 31.4.14 " ,
5
5
"homepage" : " https://github.com/DevExpress/testcafe-hammerhead" ,
6
6
"bugs" : {
7
7
"url" : " https://github.com/DevExpress/testcafe-hammerhead/issues"
Original file line number Diff line number Diff line change @@ -1005,7 +1005,7 @@ export default class ElementSandbox extends SandboxBase {
1005
1005
domProcessor . processElement ( el , urlUtils . convertToProxyUrl ) ;
1006
1006
}
1007
1007
1008
- addFileInputInfo ( el : HTMLElement ) : void {
1008
+ addFileInputInfo ( el : HTMLInputElement ) : void {
1009
1009
const infoManager = this . _uploadSandbox . infoManager ;
1010
1010
const files = infoManager . getFiles ( el ) ;
1011
1011
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ export default class UploadSandbox extends SandboxBase {
39
39
static _getCurrentInfoManager ( input : HTMLInputElement ) {
40
40
const contextWindow = input [ INTERNAL_PROPS . processedContext ] ;
41
41
42
- return getSandboxBackup ( contextWindow ) . upload . infoManager ;
42
+ return contextWindow && getSandboxBackup ( contextWindow ) . upload . infoManager ;
43
43
}
44
44
45
45
/*eslint-disable max-nested-callbacks */
@@ -97,7 +97,9 @@ export default class UploadSandbox extends SandboxBase {
97
97
}
98
98
99
99
static getUploadElementValue ( input : HTMLInputElement ) {
100
- return UploadSandbox . _getCurrentInfoManager ( input ) . getValue ( input ) ;
100
+ const infoManager = UploadSandbox . _getCurrentInfoManager ( input ) ;
101
+
102
+ return infoManager ? infoManager . getValue ( input ) : '' ;
101
103
}
102
104
103
105
setUploadElementValue ( input : HTMLInputElement , value : string ) : void {
Original file line number Diff line number Diff line change @@ -116,7 +116,7 @@ export default class UploadInfoManager {
116
116
return null ;
117
117
}
118
118
119
- getValue ( input ) {
119
+ getValue ( input : HTMLInputElement ) {
120
120
const inputInfo = this . getUploadInfo ( input ) ;
121
121
122
122
// eslint-disable-next-line no-restricted-properties
Original file line number Diff line number Diff line change @@ -45,9 +45,6 @@ const WRAP_DOCTYPE_RE = /<!doctype([^>]*)>/ig;
45
45
const WRAP_DOCTYPE_TEMPLATE = `<${ FAKE_DOCTYPE_TAG_NAME } >$1</${ FAKE_DOCTYPE_TAG_NAME } >` ;
46
46
const UNWRAP_DOCTYPE_RE = new RegExp ( `<${ FAKE_DOCTYPE_TAG_NAME } >([\\S\\s]*?)</${ FAKE_DOCTYPE_TAG_NAME } >` , 'ig' ) ;
47
47
48
- const FIND_SVG_RE = / < s v g \s ? [ ^ > ] * > / ig;
49
- const FIND_NS_ATTRS_RE = / \s (?: N S [ 0 - 9 ] + : [ ^ " ' ] + ( ' | " ) [ \S \s ] * ?\1| [ ^ : ] + : N S [ 0 - 9 ] + = (?: " " | ' ' ) ) / g;
50
-
51
48
const STORED_ATTRS_SELECTOR = ( ( ) => {
52
49
const storedAttrs = [ ] ;
53
50
You can’t perform that action at this time.
0 commit comments