From c2ad650bacfbcdc592ae52171ed9e7e88e09ebc2 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 8 Dec 2015 11:16:00 +0000 Subject: mlib: no kwargs for 1.9.3 compatibility We'll continue supporting Ruby 1.9.3 as long as Debian wheezy is supported. --- lib/dtas/mlib.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/dtas/mlib.rb') diff --git a/lib/dtas/mlib.rb b/lib/dtas/mlib.rb index c7ea1df..702ed6a 100644 --- a/lib/dtas/mlib.rb +++ b/lib/dtas/mlib.rb @@ -129,11 +129,14 @@ class DTAS::Mlib end end - def update(path, jobs: 8) + def update(path, opts = nil) # n.b. "jobs" is for CPU concurrency. Audio media is typically stored # on high-latency media or slow network file systems; so we use a high # number of jobs by default to compensate for the seek-heavy workload # this generates + opts ||= {} + jobs = opts[:jobs] || 8 + init_suffixes st = File.stat(path) # we always follow the first dir even if it's a symlink st.directory? or -- cgit v1.2.3-24-ge0c7