Skip to content

Commit

Permalink
Remove some debug code
Browse files Browse the repository at this point in the history
  • Loading branch information
GaetanF committed Jun 11, 2024
1 parent 844cbbf commit 47dcf42
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -246,9 +246,6 @@ export class DjangoPasswordAuthStrategy extends NbAuthStrategy {
if (data.hasOwnProperty('server')) {
url = data.server + url;
}
console.log(tokenKey);
console.log(this.route.snapshot);
console.log(this.route.snapshot.queryParams[tokenKey]);
data[tokenKey] = this.route.snapshot.queryParams[tokenKey];
return this.http.request(method, url, {body: data, observe: 'response'})
.pipe(
Expand Down
2 changes: 0 additions & 2 deletions src/app/@cyborg/auth/token.interceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ export class TokenInterceptor implements HttpInterceptor {
}

intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {
console.log(req.url);
console.log(req.url.indexOf('/api/v1/'));
if (req.url.includes('/api/v1/')) {
return this.authService.isAuthenticatedOrRefresh()
.pipe(
Expand Down
1 change: 0 additions & 1 deletion src/app/@cyborg/components/catalog/catalog.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,6 @@ export class CatalogComponent implements OnInit, OnDestroy {
}).onClose.subscribe((res) => {
if (res && this.formRestore.valid) {
const data = this.formRestore.value;
console.log(item);
data['archive_name'] = item.tag.archive_name;
data['item'] = '';
if (item.tag.type !== 'date') {
Expand Down
11 changes: 0 additions & 11 deletions src/app/@cyborg/components/cron-editor/cron-editor.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,6 @@ export class CronGenComponent implements OnInit, ControlValueAccessor {

const [defaultHours, defaultMinutes, defaultSeconds] = this.options.defaultTime.split(':').map(Number);

console.log('inited');

this.cronForm = new FormControl(this.cron);

this.minutesForm = this.fb.group({
Expand Down Expand Up @@ -259,13 +257,6 @@ export class CronGenComponent implements OnInit, ControlValueAccessor {
}

public handleModelChange(cron: string) {
// if (this.isDirty) {
// this.isDirty = false;
// return;
// } else {
// this.isDirty = false;
// }

this.cron = cron;

if (!this.cronIsValid(cron)) {
Expand Down Expand Up @@ -402,8 +393,6 @@ export class CronGenComponent implements OnInit, ControlValueAccessor {

this.state.advanced.expression = origCron;
}
// console.log(this.activeTab);
// console.log(this.selectedIndex);
}

private computeMinutesCron(state: any) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export interface TimePickerModel {
seconds: number;
}

function* range(start: number, end: number) {
function* range(start: number, end: number): Generator<number> {
for (let i = start; i <= end; i++) {
yield i;
}
Expand Down
2 changes: 0 additions & 2 deletions src/app/@cyborg/components/dashboard/dashboard.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ export class DashboardComponent implements AfterViewInit, OnDestroy, OnInit {

const colors: any = config.variables;
const echarts: any = config.variables.echarts;
console.log(echarts);
this.options = {
backgroundColor: echarts.bg,
tooltip: {
Expand Down Expand Up @@ -179,7 +178,6 @@ export class DashboardComponent implements AfterViewInit, OnDestroy, OnInit {
},
],
};
console.log(this.options);
this.statsService.fetch().subscribe((res) => {
for (const el of res) {
this.data.success.push([new Date(el.date).toISOString(), el.success]);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ export class UserFormComponent implements OnInit {

submitNotif() {
if (this.formNotif.value && this.userId !== 0) {
console.log(this.formNotif.value);
this.usersService.patch(this.userId, this.formNotif.value).subscribe(() => {
this.toastrService.show('', 'Notification settings updated', {
position: NbGlobalPhysicalPosition.BOTTOM_RIGHT,
Expand Down
2 changes: 0 additions & 2 deletions src/app/@cyborg/components/job-output/job-output.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ export class JobOutputComponent {
if (this.job === undefined
|| this.loading
|| this.noMore
// || ['successful', 'failed', 'finished'].indexOf(this.job.status) === -1
) {
return;
}
Expand Down Expand Up @@ -77,7 +76,6 @@ export class JobOutputComponent {
this.websocketService.send({
groups: {
jobs: ['status_changed'],
// eslint-disable-next-line @typescript-eslint/naming-convention
job_events: [String(this.jobId)]
},
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ export class JobTableComponent implements OnInit {
}

cancelItem(item): void {
console.log('tutu');
console.log(item);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ export class PolicyTableComponent implements OnInit {
}

launchPolicy(item): void {
console.log('Fire');
this.policiesService.launch(item.id).subscribe((res) => {
if (res) {
this.toastrService.show('', 'Policy Job Launched', {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ export class UserTableComponent implements OnInit {
}

viewUser(item): void {
console.log('toto');
this.router.navigate(['/user/edit/' + item.id + '/']);
}

Expand Down
1 change: 0 additions & 1 deletion src/app/@cyborg/services/clients/clients.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export class ClientsService extends CrudService {
this.http.get('/api/v1/' + this.endpoint + '/', params).subscribe((result: any) => {
subscriber.next(result.count);
}, (error) => {
// console.log('send query', error);
subscriber.error(error);
});
});
Expand Down
1 change: 0 additions & 1 deletion src/app/@cyborg/services/stats/stats.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export class StatsService extends CrudService {
this.http.get('/api/v1/' + this.endpoint + '/', params).subscribe((result: any) => {
subscriber.next(result);
}, (error) => {
// console.log('send query', error);
subscriber.error(error);
});
});
Expand Down

0 comments on commit 47dcf42

Please sign in to comment.