fix(ui): handle author adding when books are added (#1572)
This commit is contained in:
@@ -19,6 +19,7 @@ import {AuthService} from './shared/service/auth.service';
|
||||
import {CommandPaletteComponent} from './features/command-palette/command-palette.component';
|
||||
import {CommandPaletteService} from './features/command-palette/command-palette.service';
|
||||
import {LibraryImportProgressService} from './shared/service/library-import-progress.service';
|
||||
import {AuthorService} from './features/author-browser/service/author.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-root',
|
||||
@@ -37,6 +38,7 @@ export class AppComponent implements OnInit, OnDestroy {
|
||||
private appConfigService = inject(AppConfigService); // DO NOT REMOVE: Used to initialize app config on startup
|
||||
private authInit = inject(AuthInitializationService);
|
||||
private bookService = inject(BookService);
|
||||
private authorService = inject(AuthorService);
|
||||
private rxStompService = inject(RxStompService);
|
||||
private notificationEventService = inject(NotificationEventService);
|
||||
private metadataProgressService = inject(MetadataProgressService);
|
||||
@@ -109,6 +111,7 @@ export class AppComponent implements OnInit, OnDestroy {
|
||||
const book = JSON.parse(msg.body);
|
||||
this.libraryImportProgressService.recordBookAdded(book.metadata?.title || this.translocoService.translate('book.unknownTitle'));
|
||||
this.bookService.handleNewlyCreatedBook(book);
|
||||
this.authorService.handleNewlyCreatedBook(book);
|
||||
})
|
||||
);
|
||||
this.subscriptions.push(
|
||||
|
||||
Reference in New Issue
Block a user