 						self.errorCallback?(error)
 				.catch (error) ->
 					# page render failed
-					$timeout.cancel(timer)
-					if timedOut
-						self.errorCallback?('timeout')
-					else if error is 'cancelled'
+					if error is 'cancelled'
 						return # do nothing when cancelled
 					else
 						self.errorCallback?(error)

		class PDFRenderer
			JOB_QUEUE_INTERVAL: 25
			PAGE_LOAD_TIMEOUT: 60*1000
			PAGE_RENDER_TIMEOUT: 60*1000
			INDICATOR_DELAY1: 100  # time to delay before showing the indicator
			INDICATOR_DELAY2: 250  # time until the indicator starts animating


					transform: [pixelRatio, 0, 0, pixelRatio, 0, 0]
				}

				result.then () ->
					# page render success
					element.canvas.replaceWith(canvas)
					canvas.removeClass('pdfng-rendering')
					page.getTextContent().then (textContent) ->
						textLayer.setTextContent textContent
