} else if (message.equals("Invalid OAuth access token.")) { // Bogus access token
throw new InvalidAuthorizationException(FACEBOOK, message);
} else if (message.startsWith("Error validating application.")) { // Access token with incorrect app ID
throw new InvalidAuthorizationException(FACEBOOK, message);
}
throw new NotAuthorizedException(FACEBOOK, message);
} else if (statusCode == HttpStatus.FORBIDDEN) {
if (message.contains("Requires extended permission")) {
throw new InsufficientPermissionException(FACEBOOK, message.split(": ")[1]);
} else if (message.contains("Permissions error")) {
throw new InsufficientPermissionException(FACEBOOK);