I’d like more context on cursor rules

I documented my optimization and refactor work in a single MDC file, which applies to all requests. The Below is an rules I’ve write down in my mdc file

### Data Validation

  • unescape() returns strings — skip redundant array/object validation

  • Always define default parameters (like $opts['mode'] = 2)

  • Keep flags active unless deprecated; don’t delete feature toggles casually

  • Verify http_build_query() behavior for GET/POST consistency

  • Remove unused parameters like $logPrefix; pass structured arrays

But with the cursor checks it return the result like below,

function buildApiRequest($endpoint, $params, $opts) {
// Missing default params
$mode = $opts[‘mode’]; // No default value

// Redundant validation
if (is_array($params) || is_object($params)) {
    $params = json_encode($params);
}

// Deprecated flag removed accidentally
$enableFeature = false; // should be kept until fully deprecated

// Unescaped string usage
$query = http_build_query($params);
$url = $endpoint . '?' . $query;

// Unused variable
$logPrefix = '\[RequestLog\]';

return file_get_contents($url);

}

Issues (violating your cursor rules):
No default for $opts['mode']
Redundant array/object validation (unescape() would already return string)
Removed toggle flag carelessly
http_build_query() not checked for GET/POST consistency
logPrefix unused

Summary :
Even after applying the cursor rules, the updates didn’t reflect in the code. The redundant validation, missing defaults, and unused parameters remained unchanged indicating that the data validation rules in the cursor were not applied properly. This highlights the need to recheck how cursor rules are being parsed or executed during refactoring.