Skip to content

Commit 3bb50a6

Browse files
author
Jicheng Lu
committed
nullable
1 parent a33d43c commit 3bb50a6

File tree

3 files changed

+4
-35
lines changed

3 files changed

+4
-35
lines changed

src/Infrastructure/BotSharp.Abstraction/Agents/Models/AgentUtility.cs

Lines changed: 3 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ public override string ToString()
2626
public class UtilityItem
2727
{
2828
[JsonPropertyName("function_name")]
29-
public string FunctionName { get; set; } = string.Empty;
29+
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
30+
public string? FunctionName { get; set; }
3031

3132
[JsonPropertyName("template_name")]
3233
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
@@ -35,35 +36,4 @@ public class UtilityItem
3536
[JsonPropertyName("visibility_expression")]
3637
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
3738
public string? VisibilityExpression { get; set; }
38-
}
39-
40-
//public class UtilityFunction : UtilityBase
41-
//{
42-
// public UtilityFunction()
43-
// {
44-
45-
// }
46-
47-
// public UtilityFunction(string name)
48-
// {
49-
// Name = name;
50-
// }
51-
//}
52-
53-
//public class UtilityTemplate : UtilityBase
54-
//{
55-
// public UtilityTemplate()
56-
// {
57-
58-
// }
59-
60-
// public UtilityTemplate(string name)
61-
// {
62-
// Name = name;
63-
// }
64-
//}
65-
66-
//public class UtilityBase
67-
//{
68-
// public string Name { get; set; }
69-
//}
39+
}

src/Plugins/BotSharp.Plugin.MongoStorage/Models/AgentUtilityMongoElement.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public static AgentUtility ToDomainElement(AgentUtilityMongoElement utility)
4848

4949
public class AgentUtilityItemMongoElement
5050
{
51-
public string FunctionName { get; set; } = string.Empty;
51+
public string? FunctionName { get; set; }
5252
public string? TemplateName { get; set; }
5353
public string? VisibilityExpression { get; set; }
5454
}

src/Plugins/BotSharp.Plugin.Twilio/OutboundPhoneCallHandler/Functions/OutboundPhoneCallFn.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
using BotSharp.Abstraction.Files;
2-
using BotSharp.Abstraction.Files.Models;
32
using BotSharp.Abstraction.Infrastructures.Enums;
43
using BotSharp.Abstraction.Options;
54
using BotSharp.Abstraction.Routing;

0 commit comments

Comments
 (0)