fixed Buddy::getAlias(), would crash if no alias delivered
improved the call custom method and write im

took some lines from the php-src