From 2e1a6cd73ece566c4ebaf76b0b997e7fddf67fd6 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 15 Apr 2017 02:27:07 +0200 Subject: mod_storage_internal: Support the 'key' archive query field --- plugins/mod_storage_internal.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'plugins') diff --git a/plugins/mod_storage_internal.lua b/plugins/mod_storage_internal.lua index 09760838..21a63c95 100644 --- a/plugins/mod_storage_internal.lua +++ b/plugins/mod_storage_internal.lua @@ -67,6 +67,11 @@ function archive:find(username, query) local i = 0; if query then items = array(items); + if query.key then + items:filter(function (item) + return item.key == query.key; + end); + end if query.with then items:filter(function (item) return item.with == query.with; -- cgit v1.2.3