PluginProbe
xSpeed Cache: AI-Powered Performance Hub with MCP, Caching & CDN / 1.3.3
xSpeed Cache: AI-Powered Performance Hub with MCP, Caching & CDN v1.3.3
1.3.3 1.3.2 1.3.1 1.3.0 1.2.4 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 1.0.6 1.0.7 1.0.8 1.0.9 1.1.0 1.1.1 1.1.2 1.1.3 1.1.4 1.1.5 1.1.6 1.1.7 1.1.8 All 29 releases
xspeed / vendor / matthiasmullie / minify / src / Exceptions / PatternMatchException.php

PatternMatchException.php in xSpeed Cache: AI-Powered Performance Hub with MCP, Caching & CDN 1.3.3, at vendor/matthiasmullie/minify/src/Exceptions/PatternMatchException.php

37 lines 828 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /**
4 * Pattern match exception.
5 *
6 * Please report bugs on https://github.com/matthiasmullie/minify/issues
7 *
8 * @author Ere Maijala <ere.maijala@helsinki.fi>
9 * @copyright Copyright (c) 2012, Matthias Mullie. All rights reserved
10 * @license MIT License
11 */
12
13 namespace MatthiasMullie\Minify\Exceptions;
14
15 /**
16 * Pattern Match Exception Class.
17 *
18 * @author Ere Maijala <ere.maijala@helsinki.fi>
19 */
20 class PatternMatchException extends BasicException
21 {
22 /**
23 * Create an exception from preg_last_error.
24 *
25 * @param string $msg Error message
26 */
27 public static function fromLastError($msg)
28 {
29 $msg .= ': Error ' . preg_last_error();
30 if (PHP_MAJOR_VERSION >= 8) {
31 $msg .= ' - ' . preg_last_error_msg();
32 }
33
34 return new PatternMatchException($msg);
35 }
36 }
37