Fixing bug in array as props usage