Example #1
0
 public function generate_metadata()
 {
     if (!$this->certificate) {
         $this->generate_certificate();
     }
     $metadata = false;
     if ($this->owner && $this->id) {
         $metadata = array('_id' => $this->id, 'database' => Renegade::databaseForId($this->id), 'instance' => $this->type, 'owner' => $this->owner, 'certificate' => $this->certificate['key'], 'description' => $this->description, 'domain' => $this->domain, 'defaultPermissions' => $this->defaultPermissions, 'created' => Renegade::datetime(), 'type' => RenegadeConstants::kTypeApplication);
     }
     return $metadata;
 }
Example #2
0
 public function generate_metadata()
 {
     $metadata = false;
     $metadata = array('_id' => $this->channelId(), 'database' => Renegade::databaseForId($this->channelId()), 'application' => $this->application, 'label' => $this->label, 'description' => $this->description, 'defaultPermissions' => $this->defaultPermissions, 'requests' => 0, 'created' => Renegade::datetime(), 'type' => RenegadeConstants::kTypeChannel);
     return $metadata;
 }