diff options
Diffstat (limited to 'src/store.rs')
| -rw-r--r-- | src/store.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/store.rs b/src/store.rs index 04d7414..2e4f53a 100644 --- a/src/store.rs +++ b/src/store.rs @@ -134,6 +134,11 @@ impl PasteStore { self.pin_path(key).exists() } + /// Mark a paste as blocked (prevents re-import from DHT). + pub fn block(&self, key: &[u8]) { + let _ = fs::File::create(self.block_path(key)); + } + pub fn is_blocked(&self, key: &[u8]) -> bool { self.block_path(key).exists() } |