<?php
/**
 * Copyright (c) (2017) - Aikar's Minecraft Timings Parser
 *
 *  Written by Aikar <aikar@aikar.co>
 *    + Contributors (See AUTHORS)
 *
 *  http://aikar.co
 *  http://starlis.com
 *
 *  @license MIT
 *
 */

namespace Starlis\Timings;


use Stiphle\Storage\Apc;
use Stiphle\Throttle\LeakyBucket;

class TimingsThrottle extends LeakyBucket {


	/**
	 * Throttle constructor.
	 */
	public function __construct() {
		parent::__construct();
		$this->storage = new Apc();
	}

	public function throttle($key, $limit, $milliseconds) {

		$key = $this->getStorageKey($key, $limit, $milliseconds);
		$wait     = 0;
		$newRatio = $this->getNewRatio($key, $limit, $milliseconds);
		if ($newRatio > $milliseconds) {
			$wait = ceil($newRatio - $milliseconds);
		}
		if ($wait) {
			return $wait;
		}

		/**
		 * Lock, record and release
		 */
		$this->storage->lock($key);
		$newRatio = $this->getNewRatio($key, $limit, $milliseconds);
		$this->setLastRatio($key, $newRatio);
		$this->setLastRequest($key, microtime(1));
		$this->storage->unlock($key);
		return false;
	}
}

Add a custom throttle class
Add a custom throttle class

i dont want Stiphle's behavior of waiting. I want to deny the upload.
