fixed some issues in framework