Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename actions, and related function names #98

Merged
merged 1 commit into from
Aug 2, 2018

Conversation

sugyan
Copy link
Contributor

@sugyan sugyan commented Jul 31, 2018

Originally the action object was for template message only.
But now it is also used for flex message and quick replies, so we should change the name ****TemplateAction.

(Therefore, this is breaking change)

But the interface name TemplateAction is a problem...
I am planning to prepare another interface named QuickReplyAction later, but they do not contain each other. For example, URIAction can only be used with Template and Flex, CameraAction can only be used with QuickReply.

I think that it will become like this form.

type Action interface {
	json.Marshaler
}

type TemplateAction interface {
	Action
	TemplateAction()
}

type QuickReplyAction interface {
	Action
	QuickReplyAction()
}

But is the name TemplateAction strange?
Is there a more suitable name for the interface that can be used in common between Template and Flex?

@sugyan sugyan mentioned this pull request Jul 31, 2018
@suzuki-shunsuke
Copy link
Contributor

LGTM

@sugyan
Copy link
Contributor Author

sugyan commented Aug 2, 2018

Thanks!

@sugyan sugyan merged commit f1023b0 into line:master Aug 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants