예제 #1
0
// Decorators returns the trim.Decorators applied to the Compare's
// trim.Handler.
func (resource Compare) Decorators() []trim.Decorator {
	allowDecorator := decorators.AllowDecorator([]string{"GET"})
	return []trim.Decorator{allowDecorator}
}
예제 #2
0
파일: agents.go 프로젝트: jwowillo/mancalai
// Decorators returns all of the trim.Decorators applied to the Agents' Handler.
func (a *Agents) Decorators() []trim.Decorator {
	allowDecorator := decorators.AllowDecorator([]string{"GET"})
	return []trim.Decorator{allowDecorator}
}