Bugfix for issue-527