cleaned up some logic in limiter