#6026 refactor