Faster checks for unique item in array

This code uses a simple loop to check if a value is part of an array, as opposed to indexOf which is a lot slower (at least on Chrome).

See performance tests at:
http://jsperf.com/jquery-inarray-vs-underscore-indexof/4