mirror of
https://github.com/go-gitea/gitea.git
synced 2025-12-16 11:42:05 +01:00
apply suggestions, disable annoying lint rules
This commit is contained in:
parent
80e06d2b71
commit
45c17691d3
@ -77,7 +77,6 @@ linters:
|
|||||||
- name: identical-branches
|
- name: identical-branches
|
||||||
- name: if-return
|
- name: if-return
|
||||||
- name: increment-decrement
|
- name: increment-decrement
|
||||||
- name: indent-error-flow
|
|
||||||
- name: modifies-value-receiver
|
- name: modifies-value-receiver
|
||||||
- name: package-comments
|
- name: package-comments
|
||||||
- name: range
|
- name: range
|
||||||
|
|||||||
@ -406,7 +406,7 @@ export default defineConfig([
|
|||||||
'no-dupe-keys': [2],
|
'no-dupe-keys': [2],
|
||||||
'no-duplicate-case': [2],
|
'no-duplicate-case': [2],
|
||||||
'no-duplicate-imports': [0],
|
'no-duplicate-imports': [0],
|
||||||
'no-else-return': [2],
|
'no-else-return': [0],
|
||||||
'no-empty-character-class': [2],
|
'no-empty-character-class': [2],
|
||||||
'no-empty-function': [0],
|
'no-empty-function': [0],
|
||||||
'no-empty-pattern': [2],
|
'no-empty-pattern': [2],
|
||||||
|
|||||||
@ -17,10 +17,6 @@
|
|||||||
{{svg "octicon-mirror" $size}}
|
{{svg "octicon-mirror" $size}}
|
||||||
{{else if .Repo.IsFork}}
|
{{else if .Repo.IsFork}}
|
||||||
{{svg "octicon-repo-forked" $size}}
|
{{svg "octicon-repo-forked" $size}}
|
||||||
{{else if .Repo.IsPrivate}}
|
|
||||||
{{svg "octicon-repo-locked" $size}}
|
|
||||||
{{else if .Repo.IsTemplate}}
|
|
||||||
{{svg "octicon-repo-template" $size}}
|
|
||||||
{{else}}
|
{{else}}
|
||||||
{{svg "octicon-repo" $size}}
|
{{svg "octicon-repo" $size}}
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|||||||
@ -3,10 +3,7 @@ export function getRepoIcon(repo: Record<string, any>) {
|
|||||||
return 'octicon-mirror';
|
return 'octicon-mirror';
|
||||||
} else if (repo.fork) {
|
} else if (repo.fork) {
|
||||||
return 'octicon-repo-forked';
|
return 'octicon-repo-forked';
|
||||||
} else if (repo.private) {
|
} else {
|
||||||
return 'octicon-repo-locked';
|
|
||||||
} else if (repo.template) {
|
|
||||||
return `octicon-repo-template`;
|
|
||||||
}
|
|
||||||
return 'octicon-repo';
|
return 'octicon-repo';
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user