public function rpush($collection, $key, $value) { $list = $this->getKey($collection, $key, []); $list[] = $value; $this->setKey($collection, $key, $list); return count($list); }