Adding extra check for array. Related to #559.