1
0
Fork 0
forked from 0x2620/oxjs

Ox.toArray -> Ox.slice

This commit is contained in:
rolux 2013-12-01 14:57:52 +01:00
commit 031aa4367b
11 changed files with 20 additions and 20 deletions

View file

@ -222,7 +222,7 @@ Ox.decodeDeflate = function(string, callback) {
// Unfortunately, we can't synchronously set the source of an image,
// draw it onto a canvas, and read its data.
image.onload = function() {
string = Ox.toArray(Ox.canvas(image).data).map(function(value, index) {
string = Ox.slice(Ox.canvas(image).data).map(function(value, index) {
// Read one character per RGB byte, ignore ALPHA.
return index % 4 < 3 ? Ox.char(value) : '';
}).join('');