Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -141,8 +141,10 @@ def create_bibtex_entry(data):
|
|
141 |
bibtex = f"@{entry_type}{{{bibtex_id},\n"
|
142 |
for key, value in data.items():
|
143 |
if value.strip():
|
144 |
-
if key in ['volume', '
|
145 |
value = remove_punctuation(value)
|
|
|
|
|
146 |
bibtex += f" {key.lower()} = {{{value.strip()}}},\n"
|
147 |
bibtex = bibtex.rstrip(',\n') + "\n}"
|
148 |
return bibtex
|
|
|
141 |
bibtex = f"@{entry_type}{{{bibtex_id},\n"
|
142 |
for key, value in data.items():
|
143 |
if value.strip():
|
144 |
+
if key in ['volume', 'year']:
|
145 |
value = remove_punctuation(value)
|
146 |
+
if key == 'pages':
|
147 |
+
value = value.replace('p. ', '')
|
148 |
bibtex += f" {key.lower()} = {{{value.strip()}}},\n"
|
149 |
bibtex = bibtex.rstrip(',\n') + "\n}"
|
150 |
return bibtex
|