Просмотр исходного кода

Ignore heartbeat event handler params

They are not used for anything and the cause an error when
the handler is called from a scroll event.
Alberto Fernández Capel 8 лет назад
Родитель
Сommit
ae33b84289
1 измененных файлов с 3 добавлено и 4 удалено
  1. 3 4
      services/web/public/coffee/main/event.coffee

+ 3 - 4
services/web/public/coffee/main/event.coffee

@@ -37,11 +37,10 @@ define [
 
 			localStorage CACHE_KEY, curCache
 
-		_sendEditingSessionHeartbeat = (segmentation) ->
+		_sendEditingSessionHeartbeat = () ->
 			$http({
 				url: "/editingSession/#{window.project_id}",
 				method: "PUT",
-				data: segmentation,
 				headers: {
 					"X-CSRF-Token": window.csrfToken
 				}
@@ -52,10 +51,10 @@ define [
 				ga('send', 'event', category, action, label, value)
 
 
-			editingSessionHeartbeat: (segmentation = {}) ->
+			editingSessionHeartbeat: () ->
 				return unless nextHeartbeat <= new Date()
 
-				_sendEditingSessionHeartbeat(segmentation)
+				_sendEditingSessionHeartbeat()
 
 				heartbeatsSent++