Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to add new key through webtranslate client #69

Closed
mitar opened this issue Jan 29, 2013 · 4 comments
Closed

Unable to add new key through webtranslate client #69

mitar opened this issue Jan 29, 2013 · 4 comments

Comments

@mitar
Copy link
Contributor

mitar commented Jan 29, 2013

Unable to add new key through webtranslate client. I am getting TypeError: e is undefined error.

@jamuhl
Copy link
Member

jamuhl commented Jan 29, 2013

will need to have a look. thanks for reporting this.

source (unminified) is at https://github.com/jamuhl/i18next-webtranslate

@mitar
Copy link
Contributor Author

mitar commented Jan 29, 2013

OK. Saving also doesn't work for me. I am unsure how to make client use non-minizimed code to see where it fails. But it seems there is something wrong with saving. But missing key saving does work (locally). I do have:

    i18next.serveMissingKeyRoute(app).serveChangeKeyRoute(app).serveRemoveKeyRoute(app);

From checking the Firebug, there is no request even being made to the server.

OK. I found the problem. It is the same extend problem. I had to manually add:

        resChangePath: 'locales/change/__lng__/__ns__',
        resRemovePath: 'locales/remove/__lng__/__ns__',

and now it works. So things do not work if you configure i18nextWTOptions. You then have to configure all values of i18nextWTOptions.

@jamuhl
Copy link
Member

jamuhl commented Jan 29, 2013

Nice you found it that fast. Just to fix the extend for next release.

@jamuhl
Copy link
Member

jamuhl commented Feb 11, 2013

the extend function should be fixed like discribed in other pull request.

        options = options || {};
        options.i18nextWTOptions = extend(defaults.i18nextWTOptions, options.i18nextWTOptions || {}); // extend inner opts
        options = extend(defaults, options);

@jamuhl jamuhl closed this as completed Feb 11, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants