-
-
Save Zegnat/365769e7b58ca4ddea481a9ef6145647 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Make an array of all individual scopes. Scopes are delimitted by a space in IndieAuth. | |
$scopes = explode(' ', $scope); | |
// Now check in the new $scopes array if any elements match. | |
if (!in_array('create', $scopes) && !in_array('post', $scopes)) { | |
// Could not find 'create' or 'post'. Error time. | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment