fix wrong variable assignment in rich text editor