Made changes so karma tests run without failing.