Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions src/Twilio/Types/App.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
using System;

namespace Twilio.Types
{
/// <summary>
Expand All @@ -17,11 +15,6 @@ public class App : IEndpoint
/// <param name="app">App name</param>
public App(string app)
{
if (string.IsNullOrEmpty(app))
{
throw new ArgumentException("Parameter 'app' cannot be null or empty.", nameof(app));
}

if (!app.ToLower().StartsWith(PREFIX))
{
app = PREFIX + app;
Expand Down
4 changes: 1 addition & 3 deletions test/Twilio.Test/Types/AppTest.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using System;
using System;
using NUnit.Framework;
using Twilio.Exceptions;
using Twilio.Types;

namespace Twilio.Tests.Types
Expand All @@ -15,7 +14,6 @@ public void TestToString()
Assert.AreEqual("app:YOU", new App("YOU").ToString());
Assert.AreEqual("APP:HIM", new App("APP:HIM").ToString());
Assert.AreEqual("aPp:her", new App("aPp:her").ToString());
Assert.Throws<ArgumentException>(() => new App("").ToString());
Assert.AreEqual("app:AP12345?mycustomparam1=foo&mycustomparam2=bar", new App("app:AP12345?mycustomparam1=foo&mycustomparam2=bar").ToString());
Assert.AreEqual("app:AP12345?mycustomparam1=foo&mycustomparam2=bar", new App("AP12345?mycustomparam1=foo&mycustomparam2=bar").ToString());
}
Expand Down
Loading