Define delays globally, move calls to delay