Use constant#clear instead of while loop

@loganhasson #clear empties the array in one go, rather than having to loop through every element and pop it off