File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ Worker.prototype.from = function from(src, type) {
59
59
function getType ( src ) {
60
60
switch ( objType ( src ) ) {
61
61
case 'string' : return 'string' ;
62
- case 'element' : return src . nodeName . toLowerCase === 'canvas' ? 'canvas' : 'html ' ;
62
+ case 'element' : return src . nodeName . toLowerCase === 'canvas' ? 'canvas' : 'element ' ;
63
63
default : return 'unknown' ;
64
64
}
65
65
}
@@ -68,7 +68,7 @@ Worker.prototype.from = function from(src, type) {
68
68
type = type || getType ( src ) ;
69
69
switch ( type ) {
70
70
case 'string' : return this . set ( { src : createElement ( 'div' , { innerHTML : src } ) } ) ;
71
- case 'html' : return this . set ( { src : src } ) ;
71
+ case 'element' : return this . set ( { src : src } ) ;
72
72
case 'canvas' : return this . set ( { canvas : src } ) ;
73
73
case 'img' : return this . set ( { img : src } ) ;
74
74
default : return this . error ( 'Unknown source type.' ) ;
You can’t perform that action at this time.
0 commit comments