Fix bugs of the framework