Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 5a5c63f

Browse files
Instance should never be null
1 parent b18efc0 commit 5a5c63f

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

src/GitHub.Logging/Logging.cs

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -85,77 +85,77 @@ public static ILogging GetLogger(string context = null)
8585

8686
public static void Info(string s)
8787
{
88-
Instance?.Info(s);
88+
Instance.Info(s);
8989
}
9090

9191
public static void Debug(string s)
9292
{
93-
Instance?.Debug(s);
93+
Instance.Debug(s);
9494
}
9595

9696
public static void Trace(string s)
9797
{
98-
Instance?.Trace(s);
98+
Instance.Trace(s);
9999
}
100100

101101
public static void Warning(string s)
102102
{
103-
Instance?.Warning(s);
103+
Instance.Warning(s);
104104
}
105105

106106
public static void Error(string s)
107107
{
108-
Instance?.Error(s);
108+
Instance.Error(s);
109109
}
110110

111111
public static void Info(string format, params object[] objects)
112112
{
113-
Instance?.Info(format, objects);
113+
Instance.Info(format, objects);
114114
}
115115

116116
public static void Debug(string format, params object[] objects)
117117
{
118-
Instance?.Debug(format, objects);
118+
Instance.Debug(format, objects);
119119
}
120120

121121
public static void Trace(string format, params object[] objects)
122122
{
123-
Instance?.Trace(format, objects);
123+
Instance.Trace(format, objects);
124124
}
125125

126126
public static void Warning(string format, params object[] objects)
127127
{
128-
Instance?.Warning(format, objects);
128+
Instance.Warning(format, objects);
129129
}
130130

131131
public static void Error(string format, params object[] objects)
132132
{
133-
Instance?.Error(format, objects);
133+
Instance.Error(format, objects);
134134
}
135135

136136
public static void Info(Exception ex, string s)
137137
{
138-
Instance?.Info(ex, s);
138+
Instance.Info(ex, s);
139139
}
140140

141141
public static void Debug(Exception ex, string s)
142142
{
143-
Instance?.Debug(ex, s);
143+
Instance.Debug(ex, s);
144144
}
145145

146146
public static void Trace(Exception ex, string s)
147147
{
148-
Instance?.Trace(ex, s);
148+
Instance.Trace(ex, s);
149149
}
150150

151151
public static void Warning(Exception ex, string s)
152152
{
153-
Instance?.Warning(ex, s);
153+
Instance.Warning(ex, s);
154154
}
155155

156156
public static void Error(Exception ex, string s)
157157
{
158-
Instance?.Error(ex, s);
158+
Instance.Error(ex, s);
159159
}
160160
}
161161
}

0 commit comments

Comments
 (0)