I am using I18nHelper and want to translate text ‘upm.messages.install.licensing.followup.try’, which contains a parameter.
The i18n text in english is
'{0}' is installed, but not licensed. Get a license from MyAtlassian so you can use this add-on
So I am using getText('upm.messages.install.licensing.followup.try', 'text')
in order to get 'test' is installed, but not licensed. Get a license from MyAtlassian so you can use this add-on
But this is not working. I am not able to replace {0} with my string parameter.
Looks like there is a special problem with this text ‘upm.messages.install.licensing.followup.try’. It works perfectly fine with other labels, who have {0} parameters.
Any ideas?
Hi Holger,
Looks like a bug. Single quotes should be double escaped (as per MessageFormat (Java Platform SE 7 ))
As the string currently stands, it should currently be displaying as " ‘{0}’ is installed … " so the {0} isnt being replaced at all, rather than " ‘test’ is installed " as is expected.
The way to fix this is to change the i18n text to
‘’{0}‘’ is installed, but not licensed. Get a license from MyAtlassian so you can use this add-on
I’ve raised a ticket to fix [UPM-5679] - Ecosystem Jira , which you can follow to be notified when the change should be available.
Thanks
1 Like
That this is a bug scares me, because that translation text is there for years. And also the same in other languages e.g. German Manage your language preferences | Atlassian Support