IP/Port can now be changed before started.

RestVerbs added instead of Dictionary<string,string>
This commit is contained in:
high 2011-09-05 01:11:08 -04:00
parent d824e71507
commit f087ae5c83
2 changed files with 25 additions and 8 deletions

View file

@ -203,7 +203,7 @@ namespace TShockAPI
Log.ConsoleInfo("Backups " + (Backups.Interval > 0 ? "Enabled" : "Disabled"));
if (Initialized != null)
Initialized();
Initialized();
RestApi.Register(new RestCommand("/HelloWorld/name/{username}", usertest));
}
@ -237,7 +237,7 @@ namespace TShockAPI
}
//http://127.0.0.1:8080/HelloWorld/name/{username}?type=status
object usertest(Dictionary<string,string> verbs, IParameterCollection parameters, RequestEventArgs request)
object usertest(RestVerbs verbs, IParameterCollection parameters, RequestEventArgs request)
{
var ret = new Dictionary<string, string>();
var type = parameters["type"];