1
0
Fork 0
mirror of https://github.com/gocsaf/csaf.git synced 2025-12-22 05:40:11 +01:00

Add some documentation (controller)

This commit is contained in:
Fadi Abbud 2022-02-07 13:00:28 +01:00
parent b872f28acd
commit e8cbab2c29
2 changed files with 22 additions and 0 deletions

View file

@ -129,6 +129,8 @@ func (c *controller) tlpParam(r *http.Request) (tlp, error) {
return "", fmt.Errorf("unsupported TLP type '%s'", t)
}
// creates calls the "ensureFolders" functions to create the directories and files.
// It returns a struct by success, otherwise an error.
func (c *controller) create(*http.Request) (interface{}, error) {
if err := ensureFolders(c.cfg); err != nil {
return nil, err