summaryrefslogtreecommitdiffstats
path: root/modules/options/dynamic.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/options/dynamic.go')
-rw-r--r--modules/options/dynamic.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/options/dynamic.go b/modules/options/dynamic.go
index 28ed70c07d..f5235741d1 100644
--- a/modules/options/dynamic.go
+++ b/modules/options/dynamic.go
@@ -76,6 +76,11 @@ func License(name string) ([]byte, error) {
return fileFromDir(path.Join("license", name))
}
+// Labels eads the content of a specific labels from static or custom path.
+func Labels(name string) ([]byte, error) {
+ return fileFromDir(path.Join("label", name))
+}
+
// fileFromDir is a helper to read files from static or custom path.
func fileFromDir(name string) ([]byte, error) {
customPath := path.Join(setting.CustomPath, "options", name)