pterotype/inc/following.php
2018-09-19 11:47:51 -04:00

18 lines
369 B
PHP

<?php
namespace following;
$PENDING = 'PENDING';
$FOLLOWING = 'FOLLOWING';
function request_follow( $actor_id, $object_id ) {
global $wpdb;
return $wpdb->insert(
'pterotype_activitypub_following',
array( 'actor_id' => $actor_id,
'object_id' => wp_json_encode( $object ),
'state' => $PENDING
)
);
}
?>