mirror of
https://github.com/DerTyp7/teamspeak-obs-overlay.git
synced 2025-10-29 21:02:10 +01:00
api key now gets shown in console
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
const CONFIG = {
|
const CONFIG = {
|
||||||
apiKey: "",
|
apiKey: "9811add4-5ee3-436d-ae9d-d98ff53a1f12",
|
||||||
style: {
|
style: {
|
||||||
fontBackground: "rgba(19, 20, 33, 0.5)",
|
fontBackground: "rgba(19, 20, 33, 0.5)",
|
||||||
fontColor: "#ffffff",
|
fontColor: "#ffffff",
|
||||||
|
|||||||
@@ -23,10 +23,15 @@ function main() {
|
|||||||
|
|
||||||
ws.onmessage = (event) => {
|
ws.onmessage = (event) => {
|
||||||
let data = JSON.parse(event.data);
|
let data = JSON.parse(event.data);
|
||||||
console.log(data);
|
// console.log(data);
|
||||||
switch (data.type) {
|
switch (data.type) {
|
||||||
case "auth":
|
case "auth":
|
||||||
handleAuthMessage(data);
|
handleAuthMessage(data);
|
||||||
|
console.log(
|
||||||
|
"%c --> API-KEY: %s ",
|
||||||
|
"color:red;font-weight:bold;",
|
||||||
|
` ${data.payload.apiKey}`
|
||||||
|
);
|
||||||
break;
|
break;
|
||||||
case "clientMoved":
|
case "clientMoved":
|
||||||
handleClientMoved(data);
|
handleClientMoved(data);
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
function handleAuthMessage(data) {
|
function handleAuthMessage(data) {
|
||||||
console.log("Handling auth message");
|
|
||||||
channelList.setItems(
|
channelList.setItems(
|
||||||
parseChannelInfos(data.payload.connections[0].channelInfos)
|
parseChannelInfos(data.payload.connections[0].channelInfos)
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user