RIP Mixer

This commit is contained in:
Calvin Montgomery 2020-07-26 10:24:36 -07:00
parent 99af92ed2c
commit f081bc782a
9 changed files with 9 additions and 49 deletions

View file

@ -159,9 +159,10 @@ PlaylistModule.prototype.load = function (data) {
}
} else if (item.media.type === "gd") {
delete item.media.meta.gpdirect;
} else if (["vm", "jw"].includes(item.media.type)) {
} else if (["vm", "jw", "mx"].includes(item.media.type)) {
// JW has been deprecated for a long time
// VM shut down in December 2017
// Mixer shut down in July 2020
LOGGER.warn(
"Dropping playlist item with deprecated type %s",
item.media.type

View file

@ -407,16 +407,6 @@ function preprocessConfig(cfg) {
"for more information on registering a client ID");
}
if (cfg["mixer-client-id"]) {
require("cytube-mediaquery/lib/provider/mixer").setClientID(
cfg["mixer-client-id"]
);
} else {
LOGGER.warn("No Mixer Client ID set. Mixer.com links will " +
"not work. See mixer-client-id in config.template.yaml " +
"for more information on registering a client ID");
}
// Remove calzoneman from contact config (old default)
cfg.contacts = cfg.contacts.filter(contact => {
return contact.name !== 'calzoneman';

View file

@ -9,7 +9,6 @@ const Vimeo = require("cytube-mediaquery/lib/provider/vimeo");
const Streamable = require("cytube-mediaquery/lib/provider/streamable");
const TwitchVOD = require("cytube-mediaquery/lib/provider/twitch-vod");
const TwitchClip = require("cytube-mediaquery/lib/provider/twitch-clip");
const Mixer = require("cytube-mediaquery/lib/provider/mixer");
import { Counter } from 'prom-client';
import { lookup as lookupCustomMetadata } from './custom-media';
@ -546,23 +545,10 @@ var Getters = {
/* mixer.com */
mx: function (id, callback) {
let m = id.match(/^[\w-]+$/);
if (!m) {
process.nextTick(callback, "Invalid mixer.com ID");
return;
}
Mixer.lookup(id).then(stream => {
process.nextTick(callback, null, new Media(
stream.id,
stream.title,
"--:--",
"mx",
stream.meta
));
}).catch(error => {
process.nextTick(callback, error.message || error, null);
});
process.nextTick(
callback,
"As of July 2020, Mixer is no longer in service."
);
}
};