Fix for the [] nil method bug, and upgrade to angularjs.