Overview
Provides a function that loads a properties file from Appian Document Management and returns a dictionary of labels and values.
How to i18n your Form:
Key Features and Functions
Functions:
Mike Cichy Overall, this has been a great plugin but we ran into a strange error the other day. For whatever reason, the first key in this particular bundle localization file seems to be added as a string (rather than a key) to the resulting dictionary (test case 2 - viewing the expression). When we try to index() the value from the strange key, it returns a null (test case 2 - indexing the key). If the first line is a blank line, it seems like the plugin adds an empty string as the dictionary key with an empty value (test case 1).
I've built an app to reproduce the issue and highlight these test cases. As a workaround, we've simply added an empty first line before the key/value pairs. I looked through the bundle file in a text editor and haven't been able to identify any strange characters either. If someone has an answer as to what is causing this behaviour, it would be greatly appreciated. Thanks!
Test Case 1:
Test Case 2 - Viewing the expression:
Test Case 2 - Indexing the "hello" key:
Test Case Appian App: /cfs-file/__key/commentfiles/f7d226abd59f475c9d224a79e3f0ec07-bae752e8-2344-43c9-8f1e-a06bbcf919a8/Appian-i18n-Bug-Test-Case.zip
Any messages in the logs? I won't get a chance to look at this until next week.
Nope, no messages at all in the logs and the loadbundle() function does still return a dictionary. It just seems like the first line isn't behaving correctly. No worries at all, let me know what you find whenever you get the chance. Thanks in advance!