Hi, Im translating my app to english. I have a translation.lua that I require onto the scenes.
The code is
local translations = require("translations") local language local os = system.getInfo("platformName") if os == "Android" then language = system.getPreference( "locale", "language" ) print( "andorid language is ", language ) else language = system.getPreference( "ui", "language" ) end
The problem is that If I use this code on the first scene that the app goes to then “DidReceiveRemoteNotification” function stops being called. If I on the other hand put my translation lua as a table inside the scene everything works as normal. All other scenes have the same setup, its only when i use It on the first scene that the app goes to that this issue happens. At the moment my only workaround is to have a dummy scene as my first scene or put my hole translation table inside the scene.
The translation file looks like this basically looks like this but with a couple of 100 more lines so I don’t really want to put it inside the scene,
local translations = { ["Your user ID is"] = { ["en"] = "Your user ID is:", ["sv"] = "Ditt användar ID är:", }, } return translations