Skip to content

Commit a87878b

Browse files
committed
🤖 Update LLMs files [skip ci]
1 parent 0b7c047 commit a87878b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎docusaurus/static/llms-full.txt‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4713,6 +4713,10 @@ In most cases, the controllers will contain the bulk of a project's business log
47134713
<em><figcaption style={{fontSize: '12px'}}>The diagram represents a simplified version of how a request travels through the Strapi back end, with controllers highlighted. The backend customization introduction page includes a complete, <a href="/cms/backend-customization#interactive-diagram">interactive diagram</a>.</figcaption></em>
47144714
</figure>
47154715

4716+
:::caution Sanitize inputs and outputs
4717+
When overriding core actions, always validate and sanitize queries and responses to avoid leaking private fields or bypassing access rules. Use `validateQuery` (optional), `sanitizeQuery` (recommended), and `sanitizeOutput` before returning data from custom actions. See the example below for a safe `find` override.
4718+
:::
4719+
47164720
## Implementation
47174721

47184722
Controllers can be [generated or added manually](#adding-a-new-controller). Strapi provides a `createCoreController` factory function that automatically generates core controllers and allows building custom ones or [extend or replace the generated controllers](#extending-core-controllers).

0 commit comments

Comments
 (0)