Code Duplication    Length = 8-8 lines in 2 locations

Utilities.php 2 locations

@@ 176-183 (lines=8) @@
173
     *
174
     * @return string
175
     */
176
    public static function unescape($value)
177
    {
178
        $callback = function ($matches) {
179
            return chr(hexdec($matches[1]));
180
        };
181
182
        return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', $callback, $value);
183
    }
184
185
    /**
186
     * Convert a binary SID to a string SID.
@@ 408-415 (lines=8) @@
405
     * @param string $value
406
     * @return string
407
     */
408
    public static function unescapeValue($value)
409
    {
410
        $callback = function ($matches) {
411
            return chr(hexdec($matches[1]));
412
        };
413
414
        return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', $callback, $value);
415
    }
416
417
    /**
418
     * Converts a string distinguished name into its separate pieces.