fix targetUser being used before it is defined