Skip to content

Refactor SIP code for clarity and consistency#1653

Merged
sipsorcery merged 1 commit into
sipsorcery-org:masterfrom
paulomorgado:strings-4
Jun 1, 2026
Merged

Refactor SIP code for clarity and consistency#1653
sipsorcery merged 1 commit into
sipsorcery-org:masterfrom
paulomorgado:strings-4

Conversation

@paulomorgado
Copy link
Copy Markdown
Contributor

Replaced manual string comparisons with StringComparison.OrdinalIgnoreCase and placed constants first in comparisons. Refactored switch statements to use switch expressions with spans. Updated header concatenation to use string interpolation. Used string.IsNullOrWhiteSpace for null/whitespace checks. Changed method overrides to use override instead of new where appropriate.

Follow-up from #1645
Split of #1639

Replaced manual string comparisons with StringComparison.OrdinalIgnoreCase and placed constants first in comparisons. Refactored switch statements to use switch expressions with spans. Updated header concatenation to use string interpolation. Used string.IsNullOrWhiteSpace for null/whitespace checks. Changed method overrides to use override instead of new where appropriate.
@sipsorcery sipsorcery merged commit 97abf8c into sipsorcery-org:master Jun 1, 2026
6 checks passed
@sipsorcery
Copy link
Copy Markdown
Member

The size of this PR is much more manageable 👍.

paulomorgado added a commit to paulomorgado/sipsorcery-org-sipsorcery that referenced this pull request Jun 1, 2026
Replaced manual string comparisons with StringComparison.OrdinalIgnoreCase and placed constants first in comparisons. Refactored switch statements to use switch expressions with spans. Updated header concatenation to use string interpolation. Used string.IsNullOrWhiteSpace for null/whitespace checks. Changed method overrides to use override instead of new where appropriate.
paulomorgado added a commit to paulomorgado/sipsorcery-org-sipsorcery that referenced this pull request Jun 1, 2026
Replaced manual string comparisons with StringComparison.OrdinalIgnoreCase and placed constants first in comparisons. Refactored switch statements to use switch expressions with spans. Updated header concatenation to use string interpolation. Used string.IsNullOrWhiteSpace for null/whitespace checks. Changed method overrides to use override instead of new where appropriate.
sipsorcery pushed a commit that referenced this pull request Jun 1, 2026
Replaced manual string comparisons with StringComparison.OrdinalIgnoreCase and placed constants first in comparisons. Refactored switch statements to use switch expressions with spans. Updated header concatenation to use string interpolation. Used string.IsNullOrWhiteSpace for null/whitespace checks. Changed method overrides to use override instead of new where appropriate.
@paulomorgado paulomorgado mentioned this pull request Jun 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants