anchor.diff:            echo "$superuserState" > "$superuserStateFile"
           fi
         '';
  -    } // optionalAttrs (!hasCustomRedis) {
  +    } // optionalAttrs enableRedis {
         after = [ "redis-paperless-ng.service" ];
       };
   
  
positive.code:   };
  
    config = mkIf cfg.enable {
      # Enable redis if no special url is set
      services.redis.servers.paperless-ng.enable = mkIf (!hasCustomRedis) true;
  
      systemd.tmpfiles.rules = [
        "d '${cfg.dataDir}' - ${cfg.user} ${config.users.users.${cfg.user}.group} - -"
  
negative.code:       "-/etc/hosts"
        "-/etc/localtime"
        "-/run/postgresql"
      ] ++ (optional enableRedis redisServer.unixSocket);
      BindPaths = [
        cfg.consumptionDir
        cfg.dataDir
  