fix NOTIFY function