solved multiple event problem