Get current language issue

When I use

grav.language.getActive 

to check for the current language key it is empty, if default language is active and

include_default_lang

is set to false.

Is this the intended behavior and if so, how can I get the language key in the case described above?

You should use grav.language.getLanguage as it falls back to default if the “active language” information is not available. Does it work correctly in this case?

Yes it works correctly now. Thanks!