Skip to content

Commit cfa5756

Browse files
committed
CI Checks
1 parent 7ce7cc6 commit cfa5756

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

classes/dns_util.php

+11-4
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ public function get_subdomains($domain) {
9898

9999
/**
100100
* Get spf txt record contents
101+
* @param string $domain specify a different domain
101102
* @return string txt record
102103
*/
103104
public function get_spf_record($domain = '') {
@@ -134,7 +135,7 @@ public function get_mxtoolbox_spf_url() {
134135
* Returns the include if matched
135136
*
136137
* The include can have a wildcard and this will return the actual matched value.
137-
* @param string include domain
138+
* @param string $include include domain
138139
* @return string matched include
139140
*/
140141
public function include_present(string $include) {
@@ -163,6 +164,8 @@ public function get_dkim_selector() {
163164

164165
/**
165166
* Get DKIM txt record contents
167+
* @param string $selector DKIM selector
168+
* @param string $domain DKIM domain
166169
* @return string txt record
167170
*/
168171
public function get_dkim_dns_domain($selector, $domain) {
@@ -171,6 +174,7 @@ public function get_dkim_dns_domain($selector, $domain) {
171174

172175
/**
173176
* Get DKIM txt record contents
177+
* @param string $selector DKIM selector
174178
* @return string txt record
175179
*/
176180
public function get_dkim_record($selector) {
@@ -187,7 +191,7 @@ public function get_dkim_record($selector) {
187191

188192
/**
189193
* Get DKIM txt record contents
190-
* @return string txt record
194+
* @return array txt record
191195
*/
192196
public function get_dmarc_dns_record() {
193197
$domain = $this->get_noreply_domain();
@@ -215,13 +219,14 @@ public function get_dmarc_dns_record() {
215219

216220
/**
217221
* Get MX record contents
218-
* @return string txt record
222+
* @param string $domain domain to check
223+
* @return array txt record
219224
*/
220225
public function get_mx_record($domain) {
221226

222227
$records = @dns_get_record($domain, DNS_MX);
223228
if (empty($records)) {
224-
return;
229+
return [];
225230
}
226231
usort($records, function($a, $b) {
227232
if ($a['pri'] == $b['pri']) {
@@ -234,6 +239,8 @@ public function get_mx_record($domain) {
234239

235240
/**
236241
* Get matching record contents
242+
* @param string $domain domain to check
243+
* @param string $match search for specific match
237244
* @return string txt record
238245
*/
239246
public function get_matching_dns_record($domain, $match) {

0 commit comments

Comments
 (0)