fixed grant notify
This commit is contained in:
		
							parent
							
								
									34b363f4cf
								
							
						
					
					
						commit
						76dad7e100
					
				@ -61,6 +61,7 @@ bool ConnectedClient::notifyServerGroupList() {
 | 
				
			|||||||
	return true;
 | 
						return true;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
bool ConnectedClient::notifyGroupPermList(const std::shared_ptr<Group>& group, bool as_sid) {
 | 
					bool ConnectedClient::notifyGroupPermList(const std::shared_ptr<Group>& group, bool as_sid) {
 | 
				
			||||||
	Command cmd(this->getExternalType() == CLIENT_TEAMSPEAK ? group->target() == GROUPTARGET_SERVER ? "notifyservergrouppermlist" : "notifychannelgrouppermlist" : "");
 | 
						Command cmd(this->getExternalType() == CLIENT_TEAMSPEAK ? group->target() == GROUPTARGET_SERVER ? "notifyservergrouppermlist" : "notifychannelgrouppermlist" : "");
 | 
				
			||||||
	if (group->target() == GROUPTARGET_SERVER)
 | 
						if (group->target() == GROUPTARGET_SERVER)
 | 
				
			||||||
@ -94,9 +95,9 @@ bool ConnectedClient::notifyGroupPermList(const std::shared_ptr<Group>& group, b
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
		auto type = permission::resolvePermissionData(get<0>(permission_data));
 | 
							auto type = permission::resolvePermissionData(get<0>(permission_data));
 | 
				
			||||||
		if(as_sid) {
 | 
							if(as_sid) {
 | 
				
			||||||
			cmd[index]["permsid"] = type->name;
 | 
								cmd[index]["permsid"] = type->grant_name;
 | 
				
			||||||
		} else {
 | 
							} else {
 | 
				
			||||||
			cmd[index]["permid"] = (uint16_t) type->type;
 | 
								cmd[index]["permid"] = (uint16_t) (type->type | PERM_ID_GRANT);
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
		cmd[index]["permvalue"] = permission.values.value;
 | 
							cmd[index]["permvalue"] = permission.values.value;
 | 
				
			||||||
		cmd[index]["permnegated"] = permission.flags.negate;
 | 
							cmd[index]["permnegated"] = permission.flags.negate;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user