[[ Bug 13026 ]] Port bugfix to 7.0 branch
Merge pull request #980 from runrevali/bugfix-13026-7_0

[[ Bug 13026 ]] Port bugfix to 7.0 branch