patching method that was failing on empty array
Merge pull request #74 from MatthewStephens/master

patching method that was failing on empty array