*/ trait status { /** * Status * * Check document by its status * * @param array &$$errors Registry of errors * * @return ?bool Status, if found */ public function status(array &$$errors = []): ?bool { try { // Read from ArangoDB and exit (success) return $$this->document->active ?? false; } catch (exception $$e) { // Writing to the registry of errors $$errors[] = [ 'text' => $$e->getMessage(), 'file' => $$e->getFile(), 'line' => $$e->getLine(), 'stack' => $$e->getTrace() ]; } // Exit (fail) return null; } }