Rename mkcol -> mkdir

This commit is contained in:
jaina heartles 2022-12-16 02:00:26 -08:00
parent f47c1ee751
commit 471ca527bb

View file

@ -279,13 +279,13 @@ const drive = struct {
};
const Action = enum {
mkcol,
mkdir,
};
pub const Body = struct {
action: Action,
data: union(Action) {
mkcol: struct {
mkdir: struct {
name: []const u8,
},
},
@ -294,7 +294,7 @@ const drive = struct {
pub fn handler(req: anytype, res: anytype, srv: anytype) !void {
if (req.body.action != req.body.data) return error.BadRequest;
switch (req.body.data) {
.mkcol => |data| {
.mkdir => |data| {
_ = try srv.driveMkdir(req.args.path, data.name);
// TODO