minor bug fix. crash fix.