Fix dispose

This PR fixes the use of `dispose()`: `goog.dispose(object)` should be used in preference to `object.dispose()`.