mirror of
https://github.com/ThaUnknown/miru.git
synced 2026-04-06 08:09:24 +00:00
removing debug, small fixes
This commit is contained in:
parent
8b2184f871
commit
677753d323
4 changed files with 4 additions and 7 deletions
|
|
@ -10,13 +10,11 @@ window.addEventListener("paste", async e => {
|
|||
|
||||
let reader = new FileReader();
|
||||
reader.onload = e => {
|
||||
console.log(e.target.result);
|
||||
traceAnime(e.target.result, "uri")
|
||||
};
|
||||
reader.readAsDataURL(blob);
|
||||
} else if (item && item.type.indexOf("text") === 0) {
|
||||
item.getAsString(text => {
|
||||
console.log(text)
|
||||
if (torrentRx.exec(text)) {
|
||||
e.preventDefault();
|
||||
addTorrent(text);
|
||||
|
|
|
|||
|
|
@ -138,7 +138,6 @@ async function buildVideo(file, nowPlaying) {
|
|||
} else {
|
||||
bnext.removeAttribute("disabled")
|
||||
}
|
||||
console.log(playerData.nowPlaying[0])
|
||||
if (playerData.nowPlaying && playerData.nowPlaying[0] && playerData.nowPlaying[0].streamingEpisodes.length >= parseInt(playerData.nowPlaying[1])) {
|
||||
nowPlayingDisplay.textContent = `EP ${parseInt(playerData.nowPlaying[1])}${(playerData.nowPlaying[0].streamingEpisodes.length >= parseInt(playerData.nowPlaying[1])) ? " - " + episodeRx.exec(playerData.nowPlaying[0].streamingEpisodes.filter(episode => episodeRx.exec(episode.title)[1] == parseInt(playerData.nowPlaying[1]))[0].title)[2] : ""}`
|
||||
} else if (playerData.nowPlaying && playerData.nowPlaying[1]) {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ function subStream(stream) {
|
|||
} else {
|
||||
playerData.subtitleStream = new SubtitleStream()
|
||||
playerData.subtitleStream.once('tracks', pTracks => {
|
||||
console.log(pTracks)
|
||||
pTracks.forEach(track => {
|
||||
if (track.type == "ass") {
|
||||
if (!playerData.headers) {
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ const announceList = [
|
|||
throw e
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
//for debugging
|
||||
function t(a) {
|
||||
switch (a) {
|
||||
|
|
@ -120,11 +120,12 @@ async function addTorrent(magnet, media, episode) {
|
|||
bpl.setAttribute("disabled", "")
|
||||
videofile = videoFiles[0]
|
||||
}
|
||||
|
||||
if (media && episode) {
|
||||
videoFile.length ? buildVideo(videoFile[0], [media, episode]) : buildVideo(videoFiles[0], [media, episode])
|
||||
(videoFile && videoFile.length) ? buildVideo(videoFile[0], [media, episode]) : buildVideo(videoFiles[0], [media, episode])
|
||||
}
|
||||
else {
|
||||
videoFile.length ? buildVideo(videoFile[0], [media, episode]) : buildVideo(videoFiles[0], [media, episode])
|
||||
(videoFile && videoFile.length) ? buildVideo(videoFile[0], [media, episode]) : buildVideo(videoFiles[0], [media, episode])
|
||||
}
|
||||
} else {
|
||||
halfmoon.initStickyAlert({
|
||||
|
|
|
|||
Loading…
Reference in a new issue