Skip to content

Commit

Permalink
chore: fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Vilsol committed May 19, 2024
1 parent 2973c28 commit 8e83bf2
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 9 deletions.
7 changes: 4 additions & 3 deletions config/logging.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@ package config
import (
"context"
"fmt"
"github.com/Vilsol/go-pob/utils"
"github.com/lmittmann/tint"
"log/slog"
"os"
"time"

"github.com/Vilsol/go-pob/utils"
"github.com/lmittmann/tint"
)

const (
Expand Down Expand Up @@ -60,7 +61,7 @@ func (t TimeStripper) Handle(ctx context.Context, record slog.Record) error {
record.Time = time.Time{}
}

return t.Upstream.Handle(ctx, record)
return t.Upstream.Handle(ctx, record) //nolint:wrapcheck
}

func (t TimeStripper) WithAttrs(attrs []slog.Attr) slog.Handler {
Expand Down
3 changes: 1 addition & 2 deletions frontend/src/lib/components/overlays/Version.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<script lang="ts">
import { createEventDispatcher, onMount } from 'svelte';
import { dump } from '$lib/type_utils';
import { createEventDispatcher } from 'svelte';
import { syncWrap } from '$lib/go/worker';
const dispatch = createEventDispatcher();
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/lib/console_hook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const cssMap: Record<string, string> = {

const oldLog = console.log;
console.log = (...args) => {
if (args.length == 1 && (typeof args[0] === 'string')) {
if (args.length == 1 && typeof args[0] === 'string') {
const allAnsiCodes = (args[0] as string).matchAll(ansiRegex);
const cssMapped = [...allAnsiCodes].map((c) => cssMap[c[1] as string] || '');
return oldLog(args[0].replaceAll(ansiRegex, '%c'), ...cssMapped);
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/lib/type_utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const dump = (obj: any) => {
if (typeof val === 'object') {
val = dump(val);
} else if (typeof val === 'function' || typeof val === 'symbol') {
continue
continue;
}
out[name] = val;
}
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/routes/skills/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import Select from 'svelte-select';
import { GetSkillGems } from '../../lib/cache';
import { onMount } from 'svelte';
import { colorCodes, formatColors } from '../../lib/display/colors';
import { colorCodes } from '../../lib/display/colors';
import type { SkillGroupUpdate } from '../../lib/custom_types';
import type { pob, exposition } from '../../lib/types';
Expand Down
3 changes: 2 additions & 1 deletion wasm/exposition/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@ package exposition
import (
"github.com/Vilsol/crystalline"

"runtime/debug"

"github.com/Vilsol/go-pob/builds"
"github.com/Vilsol/go-pob/cache"
"github.com/Vilsol/go-pob/calculator"
"github.com/Vilsol/go-pob/config"
"github.com/Vilsol/go-pob/data/raw"
"github.com/Vilsol/go-pob/pob"
"runtime/debug"
)

func Expose() *crystalline.Exposer {
Expand Down

0 comments on commit 8e83bf2

Please sign in to comment.