moved onnotify