summaryrefslogtreecommitdiff
path: root/omptagger
diff options
context:
space:
mode:
authorDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2010-10-16 00:37:04 -0700
committerDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2010-10-16 00:37:04 -0700
commite6adaf866920ee414bdf732047859d74991e1cb9 (patch)
tree0a6bf5da816cb554287971950c7d19805a64b480 /omptagger
parent8d1d7bb3e2e6f0fb42e8756e54f13fa866575be5 (diff)
downloadomptagger-e6adaf866920ee414bdf732047859d74991e1cb9.tar.gz
omptagger-e6adaf866920ee414bdf732047859d74991e1cb9.tar.xz
Do not fail if adding a field that does not exist.
Diffstat (limited to 'omptagger')
-rwxr-xr-xomptagger7
1 files changed, 6 insertions, 1 deletions
diff --git a/omptagger b/omptagger
index 75a0b90..074c4fb 100755
--- a/omptagger
+++ b/omptagger
@@ -120,7 +120,12 @@ class Metadata
field.upcase!
- @tags[field] << value
+ if @tags.has_key?(field)
+ @tags[field] << value
+ else
+ @tags[field] = value
+ end
+
output(field, value)
@write = true