Updated JS plugin to use deliver method