public function putRawObject(RawObject $raw_object) { $sha = $raw_object->getSha(); $first = substr($sha, 0, 2); $last = substr($sha, 2); $data = gzcompress($raw_object->getType() . ' ' . $raw_object->getLength() . "" . $raw_object->getData(), 4); if (!$this->isFileRelative('objects/' . $first . '/' . $last)) { $this->writeFileRelative('objects/' . $first . '/' . $last, $data); } }