From a5018d099d3de2141217043ebc32cfb4dbfa1dd3 Mon Sep 17 00:00:00 2001
From: Kyle Evans <kevans91@users.noreply.github.com>
Date: Sat, 2 May 2020 22:57:45 -0500
Subject: [PATCH] cmd: dump: check value of skip-repository flag (#11254)

This is a boolean flag; simply checking if it's set isn't enough, we must check the value as well.

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
---
 cmd/dump.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cmd/dump.go b/cmd/dump.go
index 1d71bc8379..774b1d5d50 100644
--- a/cmd/dump.go
+++ b/cmd/dump.go
@@ -99,7 +99,7 @@ func runDump(ctx *cli.Context) error {
 
 	zip.Verbose = ctx.Bool("verbose")
 
-	if ctx.IsSet("skip-repository") {
+	if ctx.IsSet("skip-repository") && ctx.Bool("skip-repository") {
 		log.Info("Skip dumping local repositories")
 	} else {
 		log.Info("Dumping local repositories...%s", setting.RepoRootPath)