~otheb/kb

d795d4d3b538fffe36f39a12233af8b20f038145 — Olie Ayre 2 months ago 5eb69b6
Fixed bug that made PATCH requests fail

Due to use of `make` method rather than `makepart` method that was
failing upon trying to build full history when there wasn't any in the
request.
1 files changed, 1 insertions(+), 1 deletions(-)

M kb-api/main.d
M kb-api/main.d => kb-api/main.d +1 -1
@@ 168,7 168,7 @@ class router {
	@CustomMethod( "PATCH" , true , [ "([0-9]+)" ] )
	patch( ServerRequest req , ServerResponse res , string _id ) {
		writeln( "patching entry " , _id ) ;
		auto e = make( req.body ) ;
		auto e = makepart( req.body ) ;
		entry a = read( _id ) ;
		if ( a is null ) {
			res.status = StatusCodes.notFound ;