Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

inotify on linux sends a different type #91

Merged
merged 1 commit into from
Jul 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions limitador-server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use limitador::storage::infinispan::{Consistency, InfinispanStorageBuilder};
use limitador::storage::redis::{AsyncRedisStorage, CachedRedisStorage, CachedRedisStorageBuilder};
use limitador::storage::{AsyncCounterStorage, AsyncStorage};
use limitador::{AsyncRateLimiter, AsyncRateLimiterBuilder, RateLimiter, RateLimiterBuilder};
use notify::event::{DataChange, ModifyKind};
use notify::event::ModifyKind;
use notify::{Error, Event, EventKind, RecommendedWatcher, RecursiveMode, Watcher};
use std::convert::TryInto;
use std::path::Path;
Expand Down Expand Up @@ -239,7 +239,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
let mut watcher =
RecommendedWatcher::new(move |result: Result<Event, Error>| match result {
Ok(ref event) => {
if let EventKind::Modify(ModifyKind::Data(DataChange::Content)) = event.kind {
if let EventKind::Modify(ModifyKind::Data(_)) = event.kind {
let limiter = limiter.clone();
let location = event.paths.first().unwrap().clone();
handle.spawn(async move {
Expand Down