Skip to content

Commit

Permalink
bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Andras Horvath committed May 16, 2016
1 parent b923d55 commit 8e9bd01
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ubuntu_integrity_check.rb
Expand Up @@ -21,7 +21,7 @@ def test_file(f)
end

# return the filename of our db
def get_db_name
def db_name
return File.basename($0, ".*") + "_db.yml"
end

Expand All @@ -36,7 +36,7 @@ def get_files
start_dir += "/" if start_dir[-1..-1] != "/"

# get db mod time for compare
t = File.mtime(get_db_name).to_s[/[0-9]+\-[0-9]+\-[0-9]+\ *[0-9]+\:[0-9]+\:[0-9]+/]
t = File.mtime(db_name).to_s[/[0-9]+\-[0-9]+\-[0-9]+\ *[0-9]+\:[0-9]+\:[0-9]+/]
# -------------------
# --- dpkg plugin ---
# -------------------
Expand Down Expand Up @@ -76,7 +76,7 @@ def info(filename, nohash = nil)

# store data in file or return it on null input
def store(data = nil)
f = get_db_name
f = db_name
y = YAML::Store.new(f)
y.transaction{
if data
Expand Down

0 comments on commit 8e9bd01

Please sign in to comment.