{"record":{"id":"e024238b93242c37","repo":"Intervention/image","slug":"failed-to-apply-self-class-message","errorCode":null,"errorMessage":"Failed to apply {self::class}, {message}","messagePattern":"Failed to apply (.+?), (.+?)","errorType":"exception","errorClass":"ModifierException","httpStatus":null,"severity":"error","filePath":"src/Modifiers/AbstractDrawModifier.php","lineNumber":64,"sourceCode":"    {\n        $borderColor = $this->drawable()->borderColor();\n\n        if ($borderColor === null || $this->drawable()->hasBorder() === false) {\n            return Color::transparent();\n        }\n\n        return $this->driver()->decodeColor($borderColor);\n    }\n\n    /**\n     * Throw ModifierException with given message if result is false.\n     *\n     * @throws ModifierException\n     */\n    protected function abortUnless(mixed $result, string $message): void\n    {\n        if ($result === false) {\n            throw new ModifierException(\n                'Failed to apply ' . self::class . ', ' . $message,\n            );\n        }\n    }\n}\n","sourceCodeStart":46,"sourceCodeEnd":70,"githubUrl":"https://github.com/Intervention/image/blob/5598b9e39751c34afc5cdee84abef77f92c26f68/src/Modifiers/AbstractDrawModifier.php#L46-L70","documentation":"Error \"Failed to apply {self::class}, {message}\" thrown in Intervention/image.","triggerScenarios":"Thrown at src/Modifiers/AbstractDrawModifier.php:64 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the wrapped {message} for the driver-level cause and fix that first (invalid color, coordinates, or draw state)","Validate all drawing parameters (points, colors, sizes) before applying the draw modifier","Check the driver-specific documentation for the drawing primitive you use (line, polygon, ellipse, bezier)"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5598b9e39751c34afc5cdee84abef77f92c26f68","analyzedAt":"2026-08-23T02:17:31.068Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}