You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by mi...@apache.org on 2017/06/05 15:02:47 UTC

[06/14] incubator-trafficcontrol git commit: remove new_user redundant set

remove new_user redundant set


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/commit/b251c698
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/tree/b251c698
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/diff/b251c698

Branch: refs/heads/master
Commit: b251c6980662b16c0717299c56b2206cae70b804
Parents: 5098aba
Author: nir-sopher <ni...@gmail.com>
Authored: Sun Mar 19 05:19:45 2017 +0200
Committer: Jeremy Mitchell <mi...@gmail.com>
Committed: Mon Jun 5 09:01:58 2017 -0600

----------------------------------------------------------------------
 traffic_ops/app/lib/API/User.pm | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafficcontrol/blob/b251c698/traffic_ops/app/lib/API/User.pm
----------------------------------------------------------------------
diff --git a/traffic_ops/app/lib/API/User.pm b/traffic_ops/app/lib/API/User.pm
index c29d5f3..a7c06a2 100644
--- a/traffic_ops/app/lib/API/User.pm
+++ b/traffic_ops/app/lib/API/User.pm
@@ -280,7 +280,7 @@ sub create {
 		country 			=> defined_or_default($params->{country}, ""),
 		email 				=> $params->{email},
 		full_name 			=> $params->{fullName},
-		new_user 			=> ( $params->{newUser} ) ? 1 : 0,
+		new_user            		=> defined_or_default($params->{newUser}, 0),		
 		phone_number 			=> defined_or_default($params->{phoneNumber}, ""),
 		postal_code 			=> defined_or_default($params->{postalCode}, ""),
 		public_ssh_key 			=> defined_or_default($params->{publicSshKey}, ""),
@@ -288,7 +288,6 @@ sub create {
 		role 				=> $params->{role},
 		state_or_province 		=> defined_or_default($params->{stateOrProvince}, ""),
 		username 			=> $params->{username},
-		new_user            		=> defined_or_default($params->{newUser}, 0),		
 		uid                  		=> defined_or_default($params->{uid}, 0),		
 		gid                  		=> defined_or_default($params->{gid}, 0),
 		local_passwd         		=> sha1_hex($params->{localPassword} ),