Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { TitleService } from './service/title.service';
})
export class AppComponent implements OnInit, OnDestroy {
title = '';
defaultTitle = 'DSOMM beta edition';
defaultTitle = '';
subtitle = '';
menuIsOpen: boolean = true;

Expand Down
4 changes: 2 additions & 2 deletions src/app/model/activity-store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { MarkdownText } from './markdown-text';

export class ActivityFileMeta {
static DSOMM_PUBLISHER: string =
'https://github.com/devsecopsmaturitymodel/DevSecOps-MaturityModel-data/';
'https://github.com/devsecopsmaturitymodel/DevSecOps-MaturityModel-data';

version: string | null = null;
released: Date | null = null;
Expand All @@ -20,7 +20,7 @@ export class ActivityFileMeta {

getDsommVersion(): string | null {
if (this.publisher && this.publisher.startsWith(ActivityFileMeta.DSOMM_PUBLISHER)) {
return this.version;
return this.version?.startsWith('v') ? this.version : `v${this.version}`;
}
return null;
}
Expand Down
8 changes: 6 additions & 2 deletions src/app/service/loader/data-loader.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export class LoaderService {
private githubService: GithubService,
private notificationService: NotificationService
) {
this.DSOMM_MODEL_URL = this.githubService.getDsommModelUrl();
this.DSOMM_MODEL_URL = this.githubService.getDsommModelUrl() + '/tree/main/generated';
}

get datastore(): DataStore | null {
Expand Down Expand Up @@ -91,7 +91,11 @@ export class LoaderService {
if (err instanceof FileNotFoundError) {
console.error(`${perfNow()}: Missing model file: ${err?.filename || err}`);
if (err.filename && err.filename.endsWith('default/model.yaml')) {
this.notificationService.notify('Loading error', `No DSOMM model found.\n\nPlease download \`model.yaml\` from [GitHub](${this.DSOMM_MODEL_URL}).`); // eslint-disable-line
let msg: string =
`No DSOMM Model file found.\n\n` +
`Please download \`model.yaml\` from [DSOMM-data](${this.DSOMM_MODEL_URL}) on GitHub, \\\n` +
`and place it in the \`src\\assets\\default\` folder.`;
this.notificationService.notify('Loading error', msg);
} else {
this.notificationService.notify('Loading error', err.message + ': ' + err.filename);
}
Expand Down
Loading