Sorry, should have said that its for any resource that is loaded not just #1506.
I looked further into the customUrls plugin and it looks like the developer before me intended it to load only on Page Not Found system event (for loading variations of a single resource with custom slugs at the end)
However the issue as far as I can tell is the plugin is being called on every single page load, not just on Page Not Found, which is causing the error build up.
Here is the full code for the plugin:
<?php
error_reporting(E_ALL);
ini_set('display_errors','1');
if ($modx->event->name != 'OnPageNotFound') {return false;}
$alias = $modx->context->getOption('request_param_alias', 'q');
if (!isset($_REQUEST[$alias])) {return false;}
$request = $_REQUEST[$alias];
$tmp = explode('/', $request);
//echo print_r($tmp);
end($tmp);
$alias = prev($tmp);
//$modx->log(xPDO::LOG_LEVEL_DEBUG, print_r($tmp));
$subalias = prev($tmp)."/".$alias;
$subalias = prev($tmp)."/".$subalias;
//$modx->log(xPDO::LOG_LEVEL_DEBUG, 'subalias+'.$subalias);
// TODO: values mask checking!!!!
$q = $modx->newQuery('modResource');
// $tmp[5] for current degree position in tree
//echo $subalias;
$q->where( array('uri:LIKE' => "%".$subalias, 'template:IN' => array(22), 'context_key' => $modx->context->key) );
//$q->where( array('alias' => $alias, 'template:IN' => array(22), 'context_key' => $modx->context->key) );
$q->select(array('id'));
$q->prepare();
//$modx->log(xPDO::LOG_LEVEL_DEBUG, 'query+'.$q->toSQL());
$q->stmt->execute();
$cont = $q->stmt->fetch(PDO::FETCH_ASSOC);
if(!$cont) return false;
$_GET['type'] = $_REQUEST['type'] = end($tmp);
$modx->sendForward($cont['id']);
And the plug in is set to only listen to the system event OnPageNotFound.
Any how to stop this loading on all page loads?