prevent error when array inputs are empty
0.3.1