mirror of https://github.com/Chocobozzz/PeerTube
Prevent invalid end watch section warnings
parent
bc3bd960e3
commit
7815dc450e
|
@ -24,8 +24,6 @@ class MockSMTPServer {
|
|||
|
||||
this.maildev.on('new', email => {
|
||||
this.emails.push(email)
|
||||
|
||||
console.log('pushed email', email)
|
||||
})
|
||||
|
||||
this.maildev.listen(err => {
|
||||
|
|
|
@ -197,8 +197,6 @@ The link will expire within 1 hour.`
|
|||
}
|
||||
|
||||
private handleError (err: any) {
|
||||
console.log(err)
|
||||
|
||||
if (this.authService.isOTPMissingError(err)) {
|
||||
this.otpStep = true
|
||||
|
||||
|
|
|
@ -203,8 +203,6 @@ export class VideoShareComponent {
|
|||
// ---------------------------------------------------------------------------
|
||||
|
||||
async onUpdate () {
|
||||
console.log('on update')
|
||||
|
||||
if (this.playlist) {
|
||||
this.playlistUrl = await this.getPlaylistUrl()
|
||||
this.playlistEmbedUrl = await this.getPlaylistEmbedUrl()
|
||||
|
|
|
@ -180,8 +180,10 @@ class PeerTubePlugin extends Plugin {
|
|||
})
|
||||
|
||||
this.player.on('seeked', () => {
|
||||
// Don't take into account small seek events
|
||||
if (Math.abs(this.player.currentTime() - lastCurrentTime) < 3) return
|
||||
const diff = Math.floor(this.player.currentTime()) - lastCurrentTime
|
||||
|
||||
// Don't take into account small forwards
|
||||
if (diff > 0 && diff < 3) return
|
||||
|
||||
lastViewEvent = 'seek'
|
||||
})
|
||||
|
|
|
@ -106,7 +106,12 @@ export class VideoViewerStats {
|
|||
const lastSection = stats.watchSections[stats.watchSections.length - 1]
|
||||
|
||||
if (lastSection.start > currentTime) {
|
||||
logger.warn('Invalid end watch section %d. Last start record was at %d.', currentTime, lastSection.start)
|
||||
logger.debug('Invalid end watch section %d. Last start record was at %d. Starting a new section.', currentTime, lastSection.start)
|
||||
|
||||
stats.watchSections.push({
|
||||
start: currentTime,
|
||||
end: currentTime
|
||||
})
|
||||
} else {
|
||||
lastSection.end = currentTime
|
||||
}
|
||||
|
|
|
@ -44,7 +44,6 @@ export class ServersCommand extends AbstractCommand {
|
|||
|
||||
await copy(origin, join('artifacts', destname))
|
||||
}
|
||||
console.log(this.server.parallel)
|
||||
|
||||
if (this.server.parallel) {
|
||||
const promise = saveGithubLogsIfNeeded()
|
||||
|
|
Loading…
Reference in New Issue