Skip to content

Commit

Permalink
lgtm fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Longi94 committed Dec 14, 2019
1 parent fa4eceb commit cc83dbd
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion backend/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from sqlalchemy.engine.url import URL
from sqlalchemy.orm import sessionmaker, scoped_session
from config import config
from entity import *
from entity import Base

log = logging.getLogger(__name__)

Expand Down
3 changes: 1 addition & 2 deletions backend/print_ddl.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
import inspect
import entity
from entity import Base
from sqlalchemy.schema import CreateTable
from sqlalchemy.dialects import postgresql


table_classes = list(map(lambda x: x[1], inspect.getmembers(entity, inspect.isclass)))
table_classes = list(filter(lambda cls: issubclass(cls, Base) and cls != Base, table_classes))
table_classes = list(filter(lambda cls: issubclass(cls, entity.Base) and cls != entity.Base, table_classes))

for cls in table_classes:
print(CreateTable(cls.__table__).compile(dialect=postgresql.dialect()))
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import { Component, Inject } from '@angular/core';
import { Body, Quality } from 'rl-loadout-lib';
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
import { MatSelectChange } from '@angular/material/select';
import { MatSnackBar } from '@angular/material/snack-bar';
import { CloudStorageService } from '../../../../service/cloud-storage.service';
import { CreateDialog } from '../create-dialog';
import { BodiesService } from '../../../../service/items/bodies.service';
import { ProductService } from '../../../../service/product.service';
import { Product } from '../../../../model/product';

@Component({
selector: 'app-create-body',
Expand Down

0 comments on commit cc83dbd

Please sign in to comment.