resolve foundation error