1 2 3 4 5 6 7 8 9 10 11 12 13 14
<?php /** * Implements EjabberdAuthBridge. */ class BridgeGnusocial extends EjabberdAuthBridge { function isuser($username, $server) { return Nickname::isTaken($username) != null; } function auth($username, $server, $password) { return common_check_user($username, $password) instanceof User; } }