Browse Source

update post method name

main
ghost 9 months ago
parent
commit
a473a4dc39
  1. 6
      src/controller/room.php

6
src/controller/room.php

@ -48,7 +48,7 @@ class Room
foreach ((array) $this->_kevacoin->kevaFilter($namespace['namespaceId']) as $record) foreach ((array) $this->_kevacoin->kevaFilter($namespace['namespaceId']) as $record)
{ {
// Is protocol compatible post // Is protocol compatible post
if ($this->post($namespace['namespaceId'], $record['key'], [], 'txid')) if ($this->_post($namespace['namespaceId'], $record['key'], [], 'txid'))
{ {
$total++; $total++;
} }
@ -140,7 +140,7 @@ class Room
foreach ($records as $record) foreach ($records as $record)
{ {
if ($post = $this->post($namespace, $record['key'], $records, null, $time)) if ($post = $this->_post($namespace, $record['key'], $records, null, $time))
{ {
$posts[$time] = $post; $posts[$time] = $post;
} }
@ -192,7 +192,7 @@ class Room
); );
} }
public function post(string $namespace, string $key, array $posts = [], ?string $field = null, ?int &$time = 0): ?string private function _post(string $namespace, string $key, array $posts = [], ?string $field = null, ?int &$time = 0): ?string
{ {
// Check record exists // Check record exists
if (!$record = (array) $this->_kevacoin->kevaGet($namespace, $key)) if (!$record = (array) $this->_kevacoin->kevaGet($namespace, $key))

Loading…
Cancel
Save