Fix coding style

Use `goog.isDef(x) ? x : {}` instead of `x || {}`
Merge pull request #1966 from fredj/coding-style

Fix coding style