check for empty array before iterating
Merge branch 'dev'