aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/git/ref.go2
-rw-r--r--modules/process/manager.go6
-rw-r--r--modules/templates/helper_test.go4
3 files changed, 6 insertions, 6 deletions
diff --git a/modules/git/ref.go b/modules/git/ref.go
index ed801f20d5..2db630e2ea 100644
--- a/modules/git/ref.go
+++ b/modules/git/ref.go
@@ -184,7 +184,7 @@ func (ref RefName) RefGroup() string {
}
// RefType returns the simple ref type of the reference, e.g. branch, tag
-// It's differrent from RefGroup, which is using the name of the directory under .git/refs
+// It's different from RefGroup, which is using the name of the directory under .git/refs
// Here we using branch but not heads, using tag but not tags
func (ref RefName) RefType() string {
var refType string
diff --git a/modules/process/manager.go b/modules/process/manager.go
index 9c21f62152..bdc4931810 100644
--- a/modules/process/manager.go
+++ b/modules/process/manager.go
@@ -134,7 +134,7 @@ func (pm *Manager) AddTypedContext(parent context.Context, description, processT
//
// Most processes will not need to use the cancel function but there will be cases whereby you want to cancel the process but not immediately remove it from the
// process table.
-func (pm *Manager) AddContextTimeout(parent context.Context, timeout time.Duration, description string) (ctx context.Context, cancel context.CancelFunc, finshed FinishedFunc) {
+func (pm *Manager) AddContextTimeout(parent context.Context, timeout time.Duration, description string) (ctx context.Context, cancel context.CancelFunc, finished FinishedFunc) {
if timeout <= 0 {
// it's meaningless to use timeout <= 0, and it must be a bug! so we must panic here to tell developers to make the timeout correct
panic("the timeout must be greater than zero, otherwise the context will be cancelled immediately")
@@ -142,9 +142,9 @@ func (pm *Manager) AddContextTimeout(parent context.Context, timeout time.Durati
ctx, cancel = context.WithTimeout(parent, timeout)
- ctx, _, finshed = pm.Add(ctx, description, cancel, NormalProcessType, true)
+ ctx, _, finished = pm.Add(ctx, description, cancel, NormalProcessType, true)
- return ctx, cancel, finshed
+ return ctx, cancel, finished
}
// Add create a new process
diff --git a/modules/templates/helper_test.go b/modules/templates/helper_test.go
index 64f29d033e..0cefb7a6b2 100644
--- a/modules/templates/helper_test.go
+++ b/modules/templates/helper_test.go
@@ -49,9 +49,9 @@ func TestSubjectBodySeparator(t *testing.T) {
test("Multiple\n---\n-------\n---\nSeparators",
"Multiple\n",
"\n-------\n---\nSeparators")
- test("Insuficient\n--\nSeparators",
+ test("Insufficient\n--\nSeparators",
"",
- "Insuficient\n--\nSeparators")
+ "Insufficient\n--\nSeparators")
}
func TestJSEscapeSafe(t *testing.T) {