Skip to content

Commit 96cd286

Browse files
authored
Merge pull request #3 from xtrimf/support_for_triggers
change trigger suffix logic
2 parents d30bc0d + 0138458 commit 96cd286

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

go/base/context.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -863,10 +863,10 @@ func (this *MigrationContext) ReadConfigFile() error {
863863
// getGhostTriggerName generates the name of a ghost trigger, based on original trigger name
864864
// or a given trigger name
865865
func (this *MigrationContext) GetGhostTriggerName(triggerName string) string {
866-
if this.RemoveTriggerSuffix {
866+
if this.RemoveTriggerSuffix && strings.HasSuffix(triggerName, this.TriggerSuffix){
867867
return strings.TrimSuffix(triggerName, this.TriggerSuffix)
868868
}
869-
869+
// else
870870
return triggerName + this.TriggerSuffix
871871
}
872872

0 commit comments

Comments
 (0)