docs: function delegate(client, fn) {
    // Add this function to the current client
    // and wrap with a connection check
    client[fn] = function(...args) {
      let self = this;
      let p = null;
      if (sand.profiler && sand.profiler.enabled) {
        // Build the profiler request
        let req = `riak ${fn} `;
        if (args[0].bucketType) {
          req += `types/${args[0].bucketType} `;
        }
  
        if (args[0].bucket) {
          req += `bucket/${args[0].bucket} `;
        }
  
        if (args[0].indexName) {
          req += `search/${args[0].indexName} `;
        }
  
        if (args[0].q) {
          req += `query/${args[0].q.replace(/(\w+):\w+/ig, '$1:*')}`
        }
  
        p = sand.profiler.profile(req.trim());
      }
  
      return new Promise(function(resolve, reject) {
  
        function returnResult(err, response, data) {
          p && p.stop();
          if (err) {
            err = new Error(err);
            err.data = data;
            err.req = `${fn}: ${args[0]}`;
            sand.riak.error(`${err.message} ${fn}:`, ...args);
            return reject(err);
          }
  
          resolve(response);
        }
  
        client.client[fn](...args, returnResult);
      }).catch(sand.error);
    };
  }