Corrected error, meeting specs for null and empty arrays.

Closes #1