Correct, but it is defined at 17:
$crosspostt = (!empty($site->crossposttime)) ? $site->crossposttime : 2;
*$releasecleaning = new ReleaseCleaning();*
$categorize = new Category();
$maxtoprocess = 0;

and then again at 136 within a for loop
             // Question is this needed?  This is never used in the FOR 
loop, and is defined globally, did not change as I was only refactoring
*$releasecleaning = new ReleaseCleaning();*
Notice it has the same name even as the global, as if it is re-declared 
it, but since it takes no variables it does not need to be declared again.

Yet it is only used at line 187:
         // this ends the for loop here
         }
         if ($importfailed) {
             @unlink($nzbFile);
         } else {
             $relguid = sha1(uniqid('', true) . mt_rand());
             $nzb = new NZB();
             $propername = true;
             if ($usenzbname === true) {
                 $cleanerName = $usename;
             } else {
                 $cleanerName = 
$releasecleaning->releaseCleaner($subject, $groupName);
             }
             if (!is_array($cleanerName)) {


Which is outside of the for loop, as such I'm unsure why to create it in 
the for loop as it is only used in an if else and as such should be 
using the global version.  I did not change it as I only was 
refactoring, but seemed like a piece of legacy code.  Only wanted to 
bring it to your attention, since maybe there is a purpose I missed.

EIC

On 1/20/2014 12:01 PM, jonnyboy wrote:
>
> In misc/testing/nzb-import.php:
>
> > @@ -133,7 +133,8 @@ function relativeTime($_time)
> >  			$partless = preg_replace('/(\(\d+\/\d+\))?(\(\d+\/\d+\))?(\(\d+\/\d+\))?(\(\d+\/\d+\))?(\(\d+\/\d+\))?(\(\d+\/\d+\))?(\(\d+\/\d+\))?$/', 'yEnc', $firstname['0']);
> >  			$partless = preg_replace('/yEnc.*?$/i', 'yEnc', $partless);
> >  			$subject = utf8_encode(trim($partless));
> > -			$namecleaning = new NameCleaning();
> > +			// Question is this needed?  This is never used in the FOR loop, and is defined globally, did not change as I was only refactoring
>
> Its used at line 187
>
> —
> Reply to this email directly or view it on GitHub 
> <https://github.com/nZEDb/nZEDb/pull/1128/files#r9010905>.
>