Using the Facebook REST API PHP client library, it seems wise to wrap calls in try{}
thus:
require('facebook.php');
$fb = new Facebook($fbApiKey, $fbSecret);
try {
$result = $fb->api_client->some_api_method(...);
} catch (FacebookRestClientException $e) {
// now what?
}
But I'm not sure what to do with the exception, e.g. to find out what went wrong or to write a sensible message to the error log. Is there documentation for these exceptions somewhere?