PHPCS: fix remaining violations (EscapeOutput, InterpolatedNotPrepared, missing @param)
- Collapse multi-line RuntimeException throws to single line so phpcs:ignore EscapeOutput.ExceptionNotEscaped applies correctly (gateway-client, perplexity-provider, openrouter-provider) - Move phpcs:ignore InterpolatedNotPrepared from SQL string line to the get_results/get_var line where the violation fires (collector) - Add descriptions to @param trendline and @param standings in panel - Remove duplicate phpcs:ignore comment in collector Agent-Session: pr-vision rename v0.1.1
This commit is contained in:
@@ -155,10 +155,8 @@ class PRV_Perplexity_Provider implements PRV_Probe_Provider {
|
||||
*/
|
||||
private function resolve_api_key(): string {
|
||||
if ( ! defined( 'PRV_OPENROUTER_API_KEY' ) || '' === PRV_OPENROUTER_API_KEY ) {
|
||||
// phpcs:ignore WordPress.Security.EscapeOutput.ExceptionNotEscaped
|
||||
throw new \RuntimeException(
|
||||
__( 'PRV_OPENROUTER_API_KEY constant is not defined. Add it to wp-config.php.', 'pr-vision' )
|
||||
);
|
||||
// phpcs:ignore WordPress.Security.EscapeOutput.ExceptionNotEscaped -- exception message, not HTML output
|
||||
throw new \RuntimeException( __( 'PRV_OPENROUTER_API_KEY constant is not defined. Add it to wp-config.php.', 'pr-vision' ) );
|
||||
}
|
||||
return PRV_OPENROUTER_API_KEY;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user