-
Couldn't load subscription status.
- Fork 99
Update to handle the new RouterOS v7.18 api syntax with empty responses #104
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
Conversation
Changed RegEx to allow for sentences with empty values. Fixes danikf#97
Changed EnsureSingleResponse to ignore responses with only ".section" words. Fixes danikf#96
Ignore sections in EnsureSingleResponse
Fixed reading ReSentences with empty value
- Added handling for `ApiEmptySentence` in `ApiCommand.cs` to return an empty list when the first response is empty. - Introduced `!empty` case in `ApiConnection.cs` to process empty responses. - Created `ApiEmptySentence` class to manage empty response types, enhancing API functionality.
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.
Change looks elegant and follows the same conventions as already used in the project.
Update to handle the new RouterOS v7.18 api syntax with empty responses
|
Thanks! I was unsure if I should create an ApiEmptySentence or modify the ReSentence, but this way looks cleaner to me. |
|
I merged your changes into my own fork's master branch, since @danikf has been MIA for a good while. |
Add package metadata to tik4net.csproj
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.
It looks like you just merged #98 and #99 into your master branch, along with that "Prepare for nuget publishing:", so they are now part of this pull request too. Not sure there is a way to fix that without re-doing your whole pull request. 😨
I don't know if that was my doing somehow. Or if you just clicked a button to pull from upstream or something. 😟
As a reminder, it is usually a good idea to always use a branch on your fork when making a pull request. That way you don't end up with issues like this, where you accidently add more stuff to your master branch.
And as an added bonus, you can give your branches funny descriptive names.
|
You can try making a new branch from the initial commit by going here: https://github.com/xPucTu4/tik4net/tree/4d4ed75f640dfa540d16e1c270653c4532a42512 |
|
Will fix it in a minute. |

ApiEmptySentenceinApiCommand.csto return an empty list when the first response is empty.!emptycase inApiConnection.csto process empty responses.ApiEmptySentenceclass to manage empty response types, enhancing API functionality.Closes #103