Make callback optional as suggested in 47facd594f87d3fc5e4e20788b377a250eb1bdd3 by @jakearchibald