summaryrefslogtreecommitdiff
path: root/DSACore/Auxiliary/Extensions.cs
diff options
context:
space:
mode:
authorDennis Kobert <d-kobert@web.de>2019-05-19 16:03:38 +0200
committerDennis Kobert <d-kobert@web.de>2019-05-19 16:03:38 +0200
commitf89f308c525e9deebc6d2cf6416e27dfe1a299dc (patch)
tree7097ef871ead0245efda696198443eab8e443d3a /DSACore/Auxiliary/Extensions.cs
parentf3983341be939235c1a6cd522b3bb5cc318a6d1a (diff)
Cleanup DiscoBot Project
Diffstat (limited to 'DSACore/Auxiliary/Extensions.cs')
-rw-r--r--DSACore/Auxiliary/Extensions.cs18
1 files changed, 5 insertions, 13 deletions
diff --git a/DSACore/Auxiliary/Extensions.cs b/DSACore/Auxiliary/Extensions.cs
index 8ef6298..f8e9d8e 100644
--- a/DSACore/Auxiliary/Extensions.cs
+++ b/DSACore/Auxiliary/Extensions.cs
@@ -6,14 +6,10 @@
//If the original string is already longer, it is returner unmodified.
public static string AddSpaces(this string str, int length)
{
- string temp = str;
- for(int i = str.Length; i < length; i++)
- {
- temp += " ";
- }
+ var temp = str;
+ for (var i = str.Length; i < length; i++) temp += " ";
return temp;
}
-
//This mehod extends string.
@@ -21,13 +17,9 @@
//If the original string is already longer, it is returner unmodified.
public static string AddSpacesAtHead(this string str, int length)
{
- string temp = "";
- for (int i = str.Length; i < length; i++)
- {
- temp += " ";
- }
+ var temp = "";
+ for (var i = str.Length; i < length; i++) temp += " ";
return temp + str;
}
}
-
-}
+} \ No newline at end of file