remove reformatting username to query
This commit is contained in:
		
							parent
							
								
									5b19863053
								
							
						
					
					
						commit
						086a68bf58
					
				| 
						 | 
					@ -622,11 +622,6 @@ func (c *Cluster) syncRoles() (err error) {
 | 
				
			||||||
	// create list of database roles to query
 | 
						// create list of database roles to query
 | 
				
			||||||
	for _, u := range c.pgUsers {
 | 
						for _, u := range c.pgUsers {
 | 
				
			||||||
		pgRole := u.Name
 | 
							pgRole := u.Name
 | 
				
			||||||
		if u.Namespace != c.Namespace && u.Namespace != "" {
 | 
					 | 
				
			||||||
			// to avoid the conflict of having multiple users of same name
 | 
					 | 
				
			||||||
			// but each in different namespace.
 | 
					 | 
				
			||||||
			pgRole = fmt.Sprintf("%s.%s", u.Namespace, u.Name)
 | 
					 | 
				
			||||||
		}
 | 
					 | 
				
			||||||
		userNames = append(userNames, pgRole)
 | 
							userNames = append(userNames, pgRole)
 | 
				
			||||||
		// add team member role name with rename suffix in case we need to rename it back
 | 
							// add team member role name with rename suffix in case we need to rename it back
 | 
				
			||||||
		if u.Origin == spec.RoleOriginTeamsAPI && c.OpConfig.EnableTeamMemberDeprecation {
 | 
							if u.Origin == spec.RoleOriginTeamsAPI && c.OpConfig.EnableTeamMemberDeprecation {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue