Fixed bug with undefined being first value