Do I need to replace the embed code after editing a widget?

No. Your saved widget keeps the same embed code when you edit it. Changes you save are reflected in the widget anywhere that code is already embedded.