1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-04 10:19:35 +02:00
Peertube/client/src/app/+admin/system/debug/debug.component.ts
Chocobozzz 017795cf45
Execute Angular migrations
* inject() Function
 * signal inputs
 * outputs
 * signal queries
 * cleanup unused imports

https://angular.dev/reference/migrations
2025-02-19 09:58:38 +01:00

29 lines
677 B
TypeScript

import { Component, OnInit, inject } from '@angular/core'
import { Notifier } from '@app/core'
import { Debug } from '@peertube/peertube-models'
import { DebugService } from './debug.service'
@Component({
templateUrl: './debug.component.html',
styleUrls: [ './debug.component.scss' ],
imports: []
})
export class DebugComponent implements OnInit {
private debugService = inject(DebugService)
private notifier = inject(Notifier)
debug: Debug
ngOnInit (): void {
this.load()
}
load () {
this.debugService.getDebug()
.subscribe({
next: debug => this.debug = debug,
error: err => this.notifier.error(err.message)
})
}
}