components/chat.js
function toChatID(steamID) {
	steamID = Helpers.steamID(steamID);

	if (steamID.type == SteamID.Type.CLAN) {
		steamID.type = SteamID.Type.CHAT;
		steamID.instance |= SteamID.ChatInstanceFlags.Clan;
	}

	return steamID;
}
function toChatID(steamID) {
	steamID = Helpers.steamID(steamID);

	if (steamID.type == SteamID.Type.CLAN) {
		steamID.type = SteamID.Type.CHAT;
		steamID.instance |= SteamID.ChatInstanceFlags.Clan;
	}

	return steamID;
}
function toChatID ( steamID ) { steamID = Helpers . steamID ( steamID ) ; if ( steamID . type == SteamID . Type . CLAN ) { steamID . type = SteamID . Type . CHAT ; steamID . instance |= SteamID . ChatInstanceFlags . Clan ; } return steamID ; }
Private functions 
If steamID is a clan ID, converts to the appropriate chat ID. Otherwise, returns it untouched.
@param {SteamID} steamID
@returns SteamID
Private functions If steamID is a clan ID converts to the appropriate chat ID . Otherwise returns it untouched .