Check If Array Is Not Empty Javascript