Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TORController's observer events should be more concrete, and also renamed to handlers #12

Open
mxms0 opened this issue Jan 12, 2017 · 0 comments
Assignees

Comments

@mxms0
Copy link

mxms0 commented Jan 12, 2017

TORController currently has -addObserverForStatusEvents:, which passes a block with strings and dictionaries with unknown keys.

Type, severity, action, can all be made into enums. I'm not sure what currently is in args, but perhaps making that into an object too, that way it's clear what values are expected to be in it (optional).

Secondly, and feel free to correct me, they should probably be handlers, not observers, even though this is a pedantic thing. They return a bool indicating whether or not they are the designated handler (or are choosing to act as one) for the specified data.

@conradev conradev self-assigned this Feb 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants