We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e523a58 commit 082f402Copy full SHA for 082f402
src/Dplr/Dplr.php
@@ -113,7 +113,7 @@ public function getServers()
113
* Return servers list of group
114
*
115
* @access public
116
- * @param mixed $group
+ * @param string $group
117
* @return array
118
*/
119
public function getServersByGroup($group)
@@ -128,6 +128,23 @@ public function getServersByGroup($group)
128
return $servers;
129
}
130
131
+ /**
132
+ * Check server group existing
133
+ *
134
135
+ * @return bool
136
+ */
137
+ public function hasGroup($group)
138
+ {
139
+ foreach ($this->servers as $serverName => $groups) {
140
+ if (in_array($group, $groups)) {
141
+ return true;
142
+ }
143
144
+
145
+ return false;
146
147
148
/**
149
* Creating new thread
150
0 commit comments