Unverified Commit 37fda8bd authored by Wolfgang Walther's avatar Wolfgang Walther
Browse files

tmuxPlugins: allow simple overrideAttrs without function

Regular `overrideAttrs` also supports passing a plain attribute set.

Before this PR:

```
nix-repl> tmuxPlugins.battery.overrideAttrs { pname = "my-battery"; }
error: attempt to call something which is not a function but a set: {
pname = "my-battery"; }
```

After, it works.
parent baa3f517
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@ let
      rtp = "${derivation}/${path}/${rtpFilePath}";
    }
    // {
      overrideAttrs = f: mkTmuxPlugin (attrs // f attrs);
      overrideAttrs = f: mkTmuxPlugin (attrs // (if lib.isFunction f then f attrs else f));
    };

  mkTmuxPlugin =