From: <nan...@na...> - 2015-04-21 01:10:10
|
From: imakowski <ima...@gm...> --- .../Attributes/StringValidatorAttribute.cs | 2 +- src/NAnt.Core/TypeFactory.cs | 2 +- src/NAnt.SourceControl/Tasks/RTagTask.cs | 2 +- src/NAnt.SourceControl/Tasks/TagTask.cs | 2 +- src/NAnt.VSNet/SolutionBase.cs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/NAnt.Core/Attributes/StringValidatorAttribute.cs b/src/NAnt.Core/Attributes/StringValidatorAttribute.cs index 5c9d7a8..523686d 100644 --- a/src/NAnt.Core/Attributes/StringValidatorAttribute.cs +++ b/src/NAnt.Core/Attributes/StringValidatorAttribute.cs @@ -113,7 +113,7 @@ namespace NAnt.Core.Attributes { string msg = string.Format("String {0} does not match expression {1}.", value, Expression); if (null != this.ExpressionErrorMessage && - string.Empty != this.ExpressionErrorMessage) { + this.ExpressionErrorMessage.Length > 0) { msg = this.ExpressionErrorMessage; } throw new ValidationException(msg); diff --git a/src/NAnt.Core/TypeFactory.cs b/src/NAnt.Core/TypeFactory.cs index 38533b1..bc93901 100644 --- a/src/NAnt.Core/TypeFactory.cs +++ b/src/NAnt.Core/TypeFactory.cs @@ -616,7 +616,7 @@ namespace NAnt.Core { if (acceptType) { string prefix = functionSetAttribute.Prefix; - if (prefix != null && prefix != String.Empty) { + if (prefix != null && prefix.Length > 0) { prefix += "::"; } else { task.Log(Level.Warning, "Ignoring functions in type \"{0}\":" diff --git a/src/NAnt.SourceControl/Tasks/RTagTask.cs b/src/NAnt.SourceControl/Tasks/RTagTask.cs index 819152a..909d416 100644 --- a/src/NAnt.SourceControl/Tasks/RTagTask.cs +++ b/src/NAnt.SourceControl/Tasks/RTagTask.cs @@ -214,7 +214,7 @@ namespace NAnt.SourceControl.Tasks { /// </summary> protected override void AppendSubCommandArgs() { base.AppendSubCommandArgs (); - if (this.Tag != null && this.Tag != string.Empty) { + if (this.Tag != null && this.Tag.Length > 0) { this.AddArg(this.Tag); } } diff --git a/src/NAnt.SourceControl/Tasks/TagTask.cs b/src/NAnt.SourceControl/Tasks/TagTask.cs index 0536be3..81ae4f2 100644 --- a/src/NAnt.SourceControl/Tasks/TagTask.cs +++ b/src/NAnt.SourceControl/Tasks/TagTask.cs @@ -240,7 +240,7 @@ namespace NAnt.SourceControl.Tasks { /// </summary> protected override void AppendSubCommandArgs() { base.AppendSubCommandArgs (); - if (this.Tag != null && this.Tag != string.Empty) { + if (this.Tag != null && this.Tag.Length > 0) { this.AddArg(this.Tag); } } diff --git a/src/NAnt.VSNet/SolutionBase.cs b/src/NAnt.VSNet/SolutionBase.cs index 111e8a7..2db6d1f 100644 --- a/src/NAnt.VSNet/SolutionBase.cs +++ b/src/NAnt.VSNet/SolutionBase.cs @@ -396,7 +396,7 @@ namespace NAnt.VSNet { // skip the project continue; } - if (p.Guid == null || p.Guid == string.Empty) { + if (p.Guid == null || p.Guid.Length == 0) { p.Guid = FindGuidFromPath(projectPath); } -- 1.7.7 |