mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-18 17:25:16 -04:00
Log warnings when using hardcoded data.
Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
f3d1644f95
commit
574c7d1dd4
3 changed files with 16 additions and 2 deletions
|
@ -1,11 +1,14 @@
|
|||
import { Injectable } from '@nestjs/common';
|
||||
import { Injectable, Logger } from '@nestjs/common';
|
||||
import { HistoryEntryUpdateDto } from './history-entry-update.dto';
|
||||
import { HistoryEntryDto } from './history-entry.dto';
|
||||
|
||||
@Injectable()
|
||||
export class HistoryService {
|
||||
private readonly logger = new Logger(HistoryService.name);
|
||||
|
||||
getUserHistory(username: string): HistoryEntryDto[] {
|
||||
//TODO: Use the database
|
||||
this.logger.warn('Using hardcoded data!');
|
||||
return [
|
||||
{
|
||||
metadata: {
|
||||
|
@ -44,6 +47,7 @@ export class HistoryService {
|
|||
updateDto: HistoryEntryUpdateDto,
|
||||
): HistoryEntryDto {
|
||||
//TODO: Use the database
|
||||
this.logger.warn('Using hardcoded data!');
|
||||
return {
|
||||
metadata: {
|
||||
alias: null,
|
||||
|
|
|
@ -1,10 +1,13 @@
|
|||
import { Injectable } from '@nestjs/common';
|
||||
import { Injectable, Logger } from '@nestjs/common';
|
||||
import { UserInfoDto } from './user-info.dto';
|
||||
|
||||
@Injectable()
|
||||
export class UsersService {
|
||||
private readonly logger = new Logger(UsersService.name);
|
||||
|
||||
getUserInfo(): UserInfoDto {
|
||||
//TODO: Use the database
|
||||
this.logger.warn('Using hardcoded data!');
|
||||
return {
|
||||
displayName: 'foo',
|
||||
userName: 'fooUser',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue