fixes another error with @emit not working