{"record":{"id":"0d8567da55466eb3","repo":"octobercms/october","slug":"form-record-with-an-id-of-id-could-not-be-found","errorCode":null,"errorMessage":"Form record with an ID of :id could not be found.","messagePattern":"Form record with an ID of :id could not be found\\.","errorType":"exception","errorClass":"ApplicationException","httpStatus":null,"severity":"error","filePath":"modules/backend/behaviors/FormController.php","lineNumber":871,"sourceCode":"\n        $model = $this->controller->formCreateModelObject();\n\n        // Prepare query and find model record\n        $query = $model->newQuery();\n\n        // Remove multisite restriction\n        if ($this->controller->formHasMultisite($model)) {\n            $query->withSites();\n        }\n        elseif ($this->controller->formHasMultisiteGroup($model)) {\n            $query->withSiteGroups();\n        }\n\n        $this->controller->formExtendQuery($query);\n        $result = $query->find($recordId);\n\n        if (!$result) {\n            throw new ApplicationException($this->getCustomLang('notFound', null, [\n                'class' => get_class($model), 'id' => $recordId\n            ]));\n        }\n\n        $result = $this->controller->formExtendModel($result) ?: $result;\n\n        return $result;\n    }\n\n    /**\n     * extendFormFields is a static helper for extending form fields\n     * @deprecated for best performance, use Event class directly, see docs\n     * @link https://docs.octobercms.com/4.x/extend/forms/form-controller.html#extending-form-fields\n     */\n    public static function extendFormFields($callback)\n    {\n        $calledClass = self::getCalledExtensionClass();\n        Event::listen('backend.form.extendFields', function ($widget) use ($calledClass, $callback) {","sourceCodeStart":853,"sourceCodeEnd":889,"githubUrl":"https://github.com/octobercms/october/blob/b608633a7e8922487d91a8161499020121c3b3bf/modules/backend/behaviors/FormController.php#L853-L889","documentation":"Error \"Form record with an ID of :id could not be found.\" thrown in octobercms/october.","triggerScenarios":"Thrown at modules/backend/behaviors/FormController.php:871 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b608633a7e8922487d91a8161499020121c3b3bf","analyzedAt":"2026-08-21T04:24:57.515Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}