some error checking for widgets
fix typo (‘=’ ipv ‘==’)