Skip to content

Commit

Permalink
Corrected initialisation name
Browse files Browse the repository at this point in the history
  • Loading branch information
rlindsgaard committed Feb 14, 2015
1 parent 9d324f3 commit 0ab0f1b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 1 addition & 3 deletions chunkedfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
} else if(typeof exports === 'object') {
module.exports = factory();
} else {
root.chunkmanager = factory;
root.chunkedfile = factory;
}
}(this, function() {

Expand All @@ -23,7 +23,6 @@
self.addChunk = function(chunk, success, error, index) {
if(!index) index = self.size();
self.chunks[index] = chunk;
console.log("Added chunk");
if(success) success(index);
}

Expand Down Expand Up @@ -111,7 +110,6 @@

switch(message.type) {
case 'chunk':
console.log("Received chunk");
chunkedFile.addChunk(message.chunk);
break;

Expand Down
4 changes: 2 additions & 2 deletions test.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
<body style="padding: 80px 0 80px 0;">
<input type="file" id="uploadfile" />
<script src="jquery-1.9.1.min.js"></script>
<script src="chunkmanager.js"></script>
<script src="chunkedfile.js"></script>
<script>
$(document).ready(function() {
$('#uploadfile').change(function(e) {
var file = this.files[0];
var ChunkedFile = window.chunkmanager();
var ChunkedFile = window.chunkedfile();

//var cm = new ChunkManager({'filename':file.name});
var cf = ChunkedFile.fromFile({
Expand Down

0 comments on commit 0ab0f1b

Please sign in to comment.