fixed typo, when class do not have method __invoke, it's not a widget