Skip to content

Commit 8601d2f

Browse files
committed
fixing windows upload bug. issue googlecreativelab#51.
1 parent bd79b1b commit 8601d2f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

coder-apps/common/coder/static/js/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ var handleFileImport = function( ev ) {
128128
var importfile = files[0];
129129

130130
//console.log( importfile );
131-
if (!importfile.type.match('application/zip')) {
131+
if (!importfile.type.match('application/zip') && !importfile.name.match(/\.zip$/i)) {
132132
alert('This doesn\'t appear to be a Coder project zip file');
133133
return false;
134134
}

coder-apps/pi/coder/static/js/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ var handleFileImport = function( ev ) {
131131
var importfile = files[0];
132132

133133
//console.log( importfile );
134-
if (!importfile.type.match('application/zip')) {
134+
if (!importfile.type.match('application/zip') && !importfile.name.match(/\.zip$/i)) {
135135
alert('This doesn\'t appear to be a Coder project zip file');
136136
return false;
137137
}

0 commit comments

Comments
 (0)