diff options
| author | Jules Laplace <jules@okfoc.us> | 2015-02-12 11:20:43 -0500 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2015-02-12 11:20:43 -0500 |
| commit | 43b82e648535b3e919443b9778f3f9f4e3c11675 (patch) | |
| tree | ed32d9abc75ce80521abebf540412b22d52740b4 /js/clipboard.js | |
| parent | cc327f927920ad18e3725e89eefbfa03bba3d5e6 (diff) | |
fix ascii import
Diffstat (limited to 'js/clipboard.js')
| -rw-r--r-- | js/clipboard.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/js/clipboard.js b/js/clipboard.js index 0acc3c7..535e333 100644 --- a/js/clipboard.js +++ b/js/clipboard.js @@ -116,8 +116,11 @@ var clipboard = (function () { import_text: function () { var data = import_textarea.value lines = data.split("\n") - var width = lines.reduce(function(a,b){ return Math.max(a, b.length) }) + console.log(data) + console.log(lines) + var width = lines.reduce(function(a,b){ console.log(a,b); return Math.max(a, b.length) }, 0) var height = lines.length +console.log(width, height) if (width > 200) { return alert("input too wide") } |
