protected function processStatusCode($status)
{
if ($status === Aerospike::OK) {
$this->error = '';
$this->errorno = self::OK;
return true;
}
if ($status === Aerospike::ERR_UDF) {
// parse the secondary error code embedded in the error message
$rhs = strrpos($this->client->error(), ':LDT');
$lhs = strrpos($this->client->error(), ': ');
if ($rhs !== false && $lhs !== false) {
$this->errorno = (int) ltrim(substr($this->client->error(), $lhs + 2, $rhs - ($lhs + 2)), "0");
$this->error = substr($this->client->error(), $rhs + 1);
return true;
}
}
$this->error = $this->client->error();
$this->errorno = $this->client->errorno();
}