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
Add MODIFY to /network, /server and /channel #338
Conversation
Dunno if i like this idea, but at least document that ADD does the same thing if the network already exists, instead of removing that line completely. Also MODIFY should fail if the network/server/channel doesn't exist instead of being exactly the same thing as add |
Yeah, I was thinking about that, but since it is just an alias to make it more clear to users I thought the duplication of code would be more work than warranted |
I'm not fully convinced about this. I think this is a documentation issue. |
It is a documentation issue also, but adding modify doesn't add much code and it would make it more clear to users what to do. This PR is mostly help modifications but it's easy to overlook documentation when you are looking for a particular thing. |
I'm not very much in favour of this unless you actually modify |
I like the direction your code is taking, however you will need to refactor the common code parts into static methods instead of using copypasta |
hi @vague666 , I really like the change you're proposing even if it is conceptually minor. however there is still work left before I can accept it. You know what I've been thinking about may be better instead:
That would also immediately get rid of some of the code duplication I marked with A and B |
g_free_and_null(rec->own_host); | ||
rec->own_ip4 = rec->own_ip6 = NULL; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
B
Since people are confused about ADD working as modify, lets make it more clear