fix bugs when checking multiple and add support for multiple context arguments