Fixed variable overwrite issue which could cause sql errors

please see https://github.com/samcleaver/phpGSB/issues/6