all: Fix typos found by codespell (#8833)

This commit is contained in:
Dimitri Papadopoulos Orfanos 2023-03-21 08:07:28 +01:00 committed by GitHub
parent bc371eacf6
commit 526e21ae26
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
14 changed files with 24 additions and 24 deletions

View File

@ -894,7 +894,7 @@ func getReport(db *sql.DB) map[string]interface{} {
r["distributions"] = analyticsFor(distributions, len(knownDistributions))
r["featureOrder"] = featureOrder
r["locations"] = locations
r["contries"] = countryList
r["countries"] = countryList
return r
}

View File

@ -275,7 +275,7 @@ found in the LICENSE file.
<div class="col-md-6">
<table class="table table-striped">
<tbody>
{{range .contries | slice 2 1}}
{{range .countries | slice 2 1}}
<tr>
<td style="width: 45%">{{.Key}}</td>
<td style="width: 5%" class="text-right">{{if ge .Pct 10.0}}{{.Pct | printf "%.0f"}}{{else if ge .Pct 1.0}}{{.Pct | printf "%.01f"}}{{else}}{{.Pct | printf "%.02f"}}{{end}}%</td>
@ -291,7 +291,7 @@ found in the LICENSE file.
<div class="col-md-6">
<table class="table table-striped">
<tbody>
{{range .contries | slice 2 2}}
{{range .countries | slice 2 2}}
<tr>
<td style="width: 45%">{{.Key}}</td>
<td style="width: 5%" class="text-right">{{if ge .Pct 10.0}}{{.Pct | printf "%.0f"}}{{else if ge .Pct 1.0}}{{.Pct | printf "%.01f"}}{{else}}{{.Pct | printf "%.02f"}}{{end}}%</td>

View File

@ -3378,7 +3378,7 @@ angular.module('syncthing.core')
return '';
}
// When the user explicitely added a wild-card, we don't show hints.
// When the user explicitly added a wild-card, we don't show hints.
if (filterEntries.length === 1 && filterEntries[0].match === '*') {
return '';
}
@ -3413,7 +3413,7 @@ angular.module('syncthing.core')
};
$scope.validateXattrFilter = function () {
// Fitlering out empty rules when saving the config
// Filtering out empty rules when saving the config
$scope.currentFolder.xattrFilter.entries = $scope.currentFolder.xattrFilter.entries.filter(function (n) {
return n.match !== "";
});

View File

@ -1368,7 +1368,7 @@ func startWrapper(wrapper Wrapper) *testWrapper {
}
func TestInternalVersioningConfiguration(t *testing.T) {
// Verify that the versioning configuration XML seralizes to something
// Verify that the versioning configuration XML serializes to something
// reasonable.
cfg := New(device1)

View File

@ -328,8 +328,8 @@ func (w *wrapper) notifyListeners(from, to Configuration) Waiter {
wg := sync.NewWaitGroup()
wg.Add(len(w.subs))
for _, sub := range w.subs {
go func(commiter Committer) {
w.notifyListener(commiter, from, to)
go func(committer Committer) {
w.notifyListener(committer, from, to)
wg.Done()
}(sub)
}

View File

@ -34,7 +34,7 @@ func listXattr(path string) ([]string, error) {
if errors.Is(err, unix.ERANGE) || size == len(buf) {
// Buffer is too small. Try again with a zero sized buffer to
// get the size, then allocate a buffer of the correct size. We
// inlude the size == len(buf) because apparently macOS doesn't
// include the size == len(buf) because apparently macOS doesn't
// return ERANGE as it should -- no harm done, just an extra
// read if we happened to need precisely 1024 bytes on the first
// pass.

View File

@ -761,7 +761,7 @@ func (f *folder) scanSubdirsDeletedAndIgnored(subDirs []string, batch *scanBatch
fallthrough
case !file.IsIgnored() && !file.IsDeleted() && !file.IsUnsupported():
// The file is not ignored, deleted or unsupported. Lets check if
// it's still here. Simply stat:ing it wont do as there are
// it's still here. Simply stat:ing it won't do as there are
// tons of corner cases (e.g. parent dir->symlink, missing
// permissions)
if !osutil.IsDeleted(f.mtimefs, file.Name) {

View File

@ -1906,7 +1906,7 @@ func (m *model) Request(deviceID protocol.DeviceID, folder, name string, _, size
if err == nil && scanner.Validate(res.data, hash, weakHash) {
return res, nil
}
// Fall through to reading from a non-temp file, just incase the temp
// Fall through to reading from a non-temp file, just in case the temp
// file has finished downloading.
}

View File

@ -3957,7 +3957,7 @@ func TestIssue6961(t *testing.T) {
must(t, tfs.Remove(name))
m.ScanFolders()
// Drop ther remote index, add some other file.
// Drop the remote index, add some other file.
must(t, m.Index(device2, fcfg.ID, []protocol.FileInfo{{Name: "bar", RawInvalid: true, Sequence: 1}}))
// Pause and unpause folder to create new db.FileSet and thus recalculate everything

View File

@ -751,7 +751,7 @@ func TestRequestRemoteRenameChanged(t *testing.T) {
t.Error("Got more than one index update for", f.Name)
}
if f.Version.Counter(fc.id.Short()) == 0 {
// This index entry might be superseeded
// This index entry might be superseded
// by the final one or sent before it separately.
break
}

View File

@ -1994,7 +1994,7 @@ These endpoints require the \fBgui.debugging\fP configuration option to
be enabled and yield an access denied error code otherwise.
.SS GET /rest/debug/peerCompletion
.sp
Summarizes the completion precentage for each remote device. Returns an object
Summarizes the completion percentage for each remote device. Returns an object
with device IDs as keys and an integer percentage as values.
.SS GET /rest/debug/httpmetrics
.sp

View File

@ -16,8 +16,8 @@ export class CachingInterceptor implements HttpInterceptor {
constructor(private cache: RequestCacheService) { }
intercept(req: HttpRequest<any>, next: HttpHandler) {
// continue if not cachable.
if (!isCachable(req)) { return next.handle(req); }
// continue if not cacheable.
if (!isCacheable(req)) { return next.handle(req); }
const cachedResponse = this.cache.get(req);
return cachedResponse ?
@ -25,9 +25,9 @@ export class CachingInterceptor implements HttpInterceptor {
}
}
/** Is this request cachable? */
function isCachable(req: HttpRequest<any>) {
// Only GET requests are cachable
/** Is this request cacheable? */
function isCacheable(req: HttpRequest<any>) {
// Only GET requests are cacheable
return req.method === 'GET';
/*
return req.method === 'GET' &&
@ -55,4 +55,4 @@ function sendRequest(
}
})
);
}
}

View File

@ -36,7 +36,7 @@ export class DbCompletionService {
.get<Completion>(this.dbStatusUrl, httpOptions)
.pipe(
map(res => {
// Remove from array in developement
// Remove from array in development
// in-memory-web-api returns arrays
if (!environment.production) {
const a: any = res as any;
@ -48,4 +48,4 @@ export class DbCompletionService {
})
);
}
}
}

View File

@ -28,7 +28,7 @@ export class DbStatusService {
.get<Folder.Status>(this.dbStatusUrl, httpOptions)
.pipe(
map(res => {
// Remove from array in developement
// Remove from array in development
// in-memory-web-api returns arrays
if (!environment.production) {
const a: any = res as any;
@ -40,4 +40,4 @@ export class DbStatusService {
})
);
}
}
}