mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
ESLint: fix no-case-declaration violations
This commit is contained in:
@@ -57,7 +57,7 @@ export class SubmissionObjectDataService {
|
||||
return this.workspaceitemDataService.findById(id, useCachedVersionIfAvailable, reRequestOnStale, ...linksToFollow);
|
||||
case SubmissionScopeType.WorkflowItem:
|
||||
return this.workflowItemDataService.findById(id, useCachedVersionIfAvailable, reRequestOnStale, ...linksToFollow);
|
||||
default:
|
||||
default: {
|
||||
const now = new Date().getTime();
|
||||
return observableOf(new RemoteData(
|
||||
now,
|
||||
@@ -70,4 +70,5 @@ export class SubmissionObjectDataService {
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -133,9 +133,7 @@ export function dsDynamicFormControlMapFn(model: DynamicFormControlModel): Type<
|
||||
return (model instanceof DynamicListCheckboxGroupModel) ? DsDynamicListComponent : DynamicNGBootstrapCheckboxGroupComponent;
|
||||
|
||||
case DYNAMIC_FORM_CONTROL_TYPE_DATEPICKER:
|
||||
const datepickerModel = model as DynamicDatePickerModel;
|
||||
|
||||
return datepickerModel.inline ? DynamicNGBootstrapCalendarComponent : DsDatePickerInlineComponent;
|
||||
return (model as DynamicDatePickerModel).inline ? DynamicNGBootstrapCalendarComponent : DsDatePickerInlineComponent;
|
||||
|
||||
case DYNAMIC_FORM_CONTROL_TYPE_GROUP:
|
||||
return DsDynamicFormGroupComponent;
|
||||
|
@@ -51,10 +51,11 @@ export class AuthRequestServiceStub {
|
||||
public getRequest(method: string, options?: HttpOptions): Observable<any> {
|
||||
const authStatusStub: AuthStatus = new AuthStatus();
|
||||
switch (method) {
|
||||
case 'logout':
|
||||
case 'logout': {
|
||||
authStatusStub.authenticated = false;
|
||||
break;
|
||||
case 'status':
|
||||
}
|
||||
case 'status': {
|
||||
const token = ((options.headers as any).lazyUpdate[1]) ? (options.headers as any).lazyUpdate[1].value : null;
|
||||
if (this.validateToken(token)) {
|
||||
authStatusStub.authenticated = true;
|
||||
@@ -75,6 +76,7 @@ export class AuthRequestServiceStub {
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return createSuccessfulRemoteDataObject$(authStatusStub);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user