Esempio n. 1
0
func AsReleaseNotesModule(module loader.Module) (common.ReleaseNotesModule, error) {
	mod, ok := module.(common.ReleaseNotesModule)
	if !ok {
		return nil, &ErrInvalidModule{module.Id(), loader.ModuleKindReleaseNotes}
	}
	return mod, nil
}
Esempio n. 2
0
func AsIssueTrackingModule(module loader.Module) (common.IssueTrackingModule, error) {
	mod, ok := module.(common.IssueTrackingModule)
	if !ok {
		return nil, &ErrInvalidModule{module.Id(), loader.ModuleKindIssueTracking}
	}
	return mod, nil
}
Esempio n. 3
0
func AsCodeReviewModule(module loader.Module) (common.CodeReviewModule, error) {
	mod, ok := module.(common.CodeReviewModule)
	if !ok {
		return nil, &ErrInvalidModule{module.Id(), loader.ModuleKindCodeReview}
	}
	return mod, nil
}