Wrapped History API in if exists for IE8/9 support