added method call to switch