Unable to look up account-document relationship

Hi,
I am having trouble to lookup document id that links with the account.
I am trying to get the document id of the document before_relationship_delete.
Below is logic hook code I am working on
class custom_Accounts_Class {

function remove_doc_site_relation (& $bean, $event) {
$id = $bean->id ;

  if ($bean->load_relationship('documents_accounts')) {
     $GLOBALS['log']->fatal( "Found relation account/document");
  }else
$GLOBALS['log']->fatal( "NOT Found relation account/document");
  }

}
HELP!
Thanks

Hello,

I assume You have $bean of account module.

Try this

$bean->load_relationship('documents');

Thank you. I want do retrieve the document id when user edit from Account.

Thanks