I am having a hard time understanding $scope variables. I have an input field with ng-model='firstName" and a $scope variable of $scope.firstName. In my controller I set $scope.firstName = $rootScope.currentUser.firstName.
My problem is that if the user changes firstName in the input field, not only does $scope.firstName change but it also changes $rootScope.currentUser.firstName.
How can I keep this from happening? I only want to update $rootScope.currentUser.firstName if the user clicks the SAVE button.