Skip to content

Incorrect sling:basename added to the new language #181

@painttred

Description

@painttred

Steps to reproduce:

  1. Create a new dictionary with a custom basename (e.g. test-basename)
  2. Select the newly created dictionary and add a new language to it

Actual result:
The newly created language contains sling:basename set as a path to the dictionary rather than the basename that was provided initially.

Expected result:
The newly created language should contain the same basename as it was set initially during dictionary creation.

Technical details:
I see that there is a basename item that exists in the language creation component https://github.com/orbinson/aem-dictionary-translator/blob/main/ui.apps/src/main/content/jcr_root/apps/aem-dictionary-translator/content/granite/dialog/dictionary/language/create/.content.xml#L40 . However, it looks like it does not have any resource mapped to it. Because of that, basename is empty here https://github.com/orbinson/aem-dictionary-translator/blob/main/core/src/main/java/be/orbinson/aem/dictionarytranslator/services/impl/DictionaryServiceImpl.java#L118 and as a result, the path to the dictionary is set as a basename instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions