(function () { "use strict"; angular.module('streamApp').controller("firstMemoryController", FirstMemoryController); FirstMemoryController.$inject = ['$scope', 'userService', '$location', '$routeParams']; function FirstMemoryController($scope, userService, $location, $routeParams) { if ($routeParams.id) { userService.getPrompt($routeParams.id).then(prompt => $scope.prompt = prompt ); } $scope.callback = function (content, dropId) { if (content && content.length > 40) { gtag_report_conversion(); } $location.url('congratulations?dropId=' + dropId); }; function gtag_report_conversion(url) { var callback = function () { if (typeof(url) != 'undefined') { window.location = url; } }; gtag('event', 'conversion', { 'send_to': 'AW-696539402/JgVzCOqWk80BEIqykcwC', 'event_callback': callback }); return false; } } })();