Pass notice to beforeNotify instead. Add tests.