[PR #22] [MERGED] Add MX priorities #53

Closed
opened 2026-03-04 23:24:04 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/yswery/PHP-DNS-SERVER/pull/22
Author: @samuelwilliams
Created: 4/17/2017
Status: Merged
Merged: 4/23/2017
Merged by: @yswery

Base: masterHead: master


📝 Commits (2)

  • 4120da3 Use correct InvalidArgumentException.
  • fbec996 Fixed MX response.

📊 Changes

5 files changed (+42 additions, -16 deletions)

View changed files

📝 dns_record.json (+10 -0)
📝 src/JsonStorageProvider.php (+1 -1)
📝 src/Server.php (+21 -13)
📝 tests/JsonStorageProviderTest.php (+5 -1)
📝 tests/test_records.json (+5 -1)

📄 Description

The server will now handle MX priorities rather than assign a default "10" to every record. Backward compatibility is maintained so that "10" is the default priority. This addresses issue #10.

The MX RDATA record SHOULD now be an associative array of the format ['priority'=>10, 'target'=>'mail.example.com.']

Additional housekeeping includes:

  • Using the correct instance of \InvalidArgumentException (my IDE autocompleted without me noticing.)
  • Getting rid of some repeated code.
  • Some minor pedantic CS fixes.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/yswery/PHP-DNS-SERVER/pull/22 **Author:** [@samuelwilliams](https://github.com/samuelwilliams) **Created:** 4/17/2017 **Status:** ✅ Merged **Merged:** 4/23/2017 **Merged by:** [@yswery](https://github.com/yswery) **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (2) - [`4120da3`](https://github.com/yswery/PHP-DNS-SERVER/commit/4120da3fb7cd11194bf273ebcd93a71e3519cced) Use correct InvalidArgumentException. - [`fbec996`](https://github.com/yswery/PHP-DNS-SERVER/commit/fbec996db21ae0ffcd13286975d53c0bcf7d6cb4) Fixed MX response. ### 📊 Changes **5 files changed** (+42 additions, -16 deletions) <details> <summary>View changed files</summary> 📝 `dns_record.json` (+10 -0) 📝 `src/JsonStorageProvider.php` (+1 -1) 📝 `src/Server.php` (+21 -13) 📝 `tests/JsonStorageProviderTest.php` (+5 -1) 📝 `tests/test_records.json` (+5 -1) </details> ### 📄 Description The server will now handle MX priorities rather than assign a default "10" to every record. Backward compatibility is maintained so that "10" is the default priority. This addresses issue #10. The MX RDATA record SHOULD now be an associative array of the format `['priority'=>10, 'target'=>'mail.example.com.']` Additional housekeeping includes: * Using the correct instance of `\InvalidArgumentException` (my IDE autocompleted without me noticing.) * Getting rid of some repeated code. * Some minor pedantic CS fixes. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-04 23:24:04 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/PHP-DNS-SERVER#53
No description provided.