When I run the following code:
$user = new midgard_user($lokin_tokens);
$user->login();
$t = new midgard_topic;
$t->create();
$t->approve();
var_dump($t->is_approved());
$t = new midgard_topic($t->id);
var_dump($t->is_approved());
$t->update();
var_dump($t->is_approved());
$t = new midgard_topic($t->id);
var_dump($t->is_approved());
I would expect this output:
bool(true)
bool(true)
bool(false)
bool(false)
instead, I get:
bool(true)
bool(true)
bool(true)
bool(true)
Not sure if I'm missing something here, but shouldn't approval be automatically revoked when the object changes? At least I always thought that is_approved() implicitly checks that metadata.revised <= metadata.approved
When I run the following code:
I would expect this output:
instead, I get:
Not sure if I'm missing something here, but shouldn't approval be automatically revoked when the object changes? At least I always thought that
is_approved()implicitly checks thatmetadata.revised <= metadata.approved