mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-10-25 20:47:48 -04:00
fix staticcheck
This commit is contained in:
1 parent
5a72cd9616
commit
b138ec1b0f
2 files changed
+2
-2
No files matched your search
@@ -36,7 +36,7 @@ func runAqueousBindEdit(cmd *cobra.Command, args []string, remove bool) {
|
||||
if !remove {
|
||||
for _, flag := range []string{"desc", "allow-when-locked", "cooldown-ms", "no-repeat", "no-inhibiting", "flags"} {
|
||||
if cmd.Flags().Changed(flag) {
|
||||
failAqueousBindEdit(cmd, fmt.Errorf("Aqueous does not support --%s in this provider", flag))
|
||||
failAqueousBindEdit(cmd, fmt.Errorf("aqueous does not support --%s in this provider", flag))
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
@@ -98,7 +98,7 @@ func parseAqueousSnapshot(data []byte) (aqueousSnapshotModel, error) {
|
||||
return model, err
|
||||
}
|
||||
if batch.Error != "" {
|
||||
return model, errors.New("Aqueous state is unavailable in the running DMS shell")
|
||||
return model, errors.New("aqueous state is unavailable in the running DMS shell")
|
||||
}
|
||||
if batch.Schema != 1 || batch.Type != "snapshot" || !bytes.Equal(batch.BaseSequence, []byte("null")) || batch.Upsert == nil || batch.Removed == nil || len(batch.Removed) != 0 || !regexp.MustCompile(`^[0-9a-f]{32}$`).MatchString(batch.Session) || !regexp.MustCompile(`^[0-9]+$`).MatchString(batch.Sequence) {
|
||||
return model, errors.New("invalid Aqueous shell snapshot")
|
||||
|
||||
Reference in new issue
Block a user