Javascript Quicksort