Skip to content

Commit

Permalink
fixed errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ParisNeo committed Aug 27, 2023
1 parent a1e9e73 commit 07c1183
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 5 deletions.
11 changes: 7 additions & 4 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -939,10 +939,13 @@ def list_models(self):

def get_active_model(self):
if self.binding is not None:
models = self.binding.list_models(self.config)
index = models.index(self.config.model_name)
ASCIIColors.yellow("Listing models")
return jsonify({"model":models[index],"index":index})
try:
models = self.binding.list_models(self.config)
index = models.index(self.config.model_name)
ASCIIColors.yellow("Listing models")
return jsonify({"model":models[index],"index":index})
except Exception as ex:
return jsonify(None)
else:
return jsonify(None)

Expand Down
10 changes: 9 additions & 1 deletion presets/build_latex_book.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,12 @@ content: |
\chapter{Introduction}
@<generation_placeholder>@
\end{document}
```
```
snippets:
- Import graphics(required to add graphics to the page) :
\usepackage[demo]{graphic}
- Add graph: |
\includegraphics[width=4in]{@<Image name>@}% Replace with your own image path
help: |
Builds a latex code for a book
File renamed without changes.

0 comments on commit 07c1183

Please sign in to comment.