<commit_before>(function() {
    'use strict';
    
    angular
        .module('lecturer')
        .controller('LoginCtrl', LoginController);

    /* @ngInject */
    function LoginController(lecturerFactory, $location) {
        console.log('Ready (Login Controller)');
        angular.element('#login-btn').addClass('active');

        if (lecturerFactory.isLoggedIn()) {
            $location.path('/courses');
        }

        var vm = this;
        vm.loginAttempt = false;
        vm.form = {};
        vm.loginUser = loginUser;

        function loginUser() {
            lecturerFactory.login(vm.form,
                function() {
                    $location.path('/lectures/1');
                },
                function() {
                    vm.loginAttempt = true;
                    vm.feedbackMessage = 'Wrong user credentials';
                    vm.feedbackType = 'alert-danger';
                    vm.feedbackIcon = 'glyphicon-exclamation-sign';
                }
            );
        }
    }
})();<commit_msg>Change to courses page in stead of lecture 1 when logging in<commit_after>(function() {
    'use strict';
    
    angular
        .module('lecturer')
        .controller('LoginCtrl', LoginController);

    /* @ngInject */
    function LoginController(lecturerFactory, $location) {
        console.log('Ready (Login Controller)');
        angular.element('#login-btn').addClass('active');

        if (lecturerFactory.isLoggedIn()) {
            $location.path('/courses');
        }

        var vm = this;
        vm.loginAttempt = false;
        vm.form = {};
        vm.loginUser = loginUser;

        function loginUser() {
            lecturerFactory.login(vm.form,
                function() {
                    $location.path('/courses');
                },
                function() {
                    vm.loginAttempt = true;
                    vm.feedbackMessage = 'Wrong user credentials';
                    vm.feedbackType = 'alert-danger';
                    vm.feedbackIcon = 'glyphicon-exclamation-sign';
                }
            );
        }
    }
})();
{'fraction_non_alphanumeric': 0.1275894538606403, 'fraction_numerical': 0.0009416195856873823, 'mean_word_length': 1.5207591933570581, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2641496', 'n_tokens_mistral': 567, 'n_tokens_neox': 525, 'n_words': 95}