1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
This commit is contained in:
SangWon Kim 2017-08-01 10:59:52 +09:00 committed by Arunoda Susiripala
parent f0779e95d6
commit 37362c3e98

View file

@ -36,7 +36,7 @@ if (!i18n.isInitialized) i18n.init(options)
// a simple helper to getInitialProps passed on loaded i18n data // a simple helper to getInitialProps passed on loaded i18n data
i18n.getInitialProps = (req, namespaces) => { i18n.getInitialProps = (req, namespaces) => {
if (!namespaces) namespaces = i18n.options.defautlNS if (!namespaces) namespaces = i18n.options.defaultNS
if (typeof namespaces === 'string') namespaces = [namespaces] if (typeof namespaces === 'string') namespaces = [namespaces]
req.i18n.toJSON = () => null // do not serialize i18next instance and send to client req.i18n.toJSON = () => null // do not serialize i18next instance and send to client