Merge branch 'dev' into refactor/common
This commit is contained in:
commit
a4408b5bc0
145 changed files with 3437 additions and 2822 deletions
|
@ -4,12 +4,12 @@ export function isValidHttpUrl(url: string): boolean {
|
|||
try {
|
||||
const parsedUrl = new URL(url, 'http://test.be');
|
||||
return parsedUrl.protocol === 'http:' || parsedUrl.protocol === 'https:';
|
||||
} catch (e) {
|
||||
} catch (_) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
export function getUrlStringForLearningObject(learningObjectId: LearningObjectIdentifier) {
|
||||
export function getUrlStringForLearningObject(learningObjectId: LearningObjectIdentifier): string {
|
||||
let url = `/learningObject/${learningObjectId.hruid}/html?language=${learningObjectId.language}`;
|
||||
if (learningObjectId.version) {
|
||||
url += `&version=${learningObjectId.version}`;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue