Merge pull request #4 from dan-lyn/master

check if array keys are set