mirror of
https://github.com/sakaljurgis/kodi-api-server.git
synced 2026-07-08 20:37:41 +00:00
streamer service: split to separate files
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import { Request, Response } from 'express';
|
||||
import { StreamerService } from './streamer.service';
|
||||
import { FileStreamerService } from './StreamerService/file-streamer.service';
|
||||
|
||||
@Injectable()
|
||||
export class StreamerFacade {
|
||||
constructor(private readonly streamerService: StreamerService) {}
|
||||
constructor(private readonly fileStreamerService: FileStreamerService) {}
|
||||
|
||||
streamFile(request: Request, response: Response, filePath: string): void {
|
||||
this.streamerService.streamFile(request, response, filePath);
|
||||
async streamFile(
|
||||
request: Request,
|
||||
response: Response,
|
||||
filePath: string,
|
||||
): Promise<void> {
|
||||
return this.fileStreamerService.streamFile(request, response, filePath);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user