prevent from crash changing file selection