Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve comments and documentation in fj-host #988

Merged
merged 3 commits into from
Aug 24, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions crates/fj-host/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,10 @@ pub struct Model {
}

impl Model {
/// Initialize the model using the path to its crate (i.e. the folder
/// containing `Cargo.toml`).
/// Initialize the model using the path to its crate
///
/// Optionally, the target directory where plugin files are compiled to can
/// be provided. If it is not provided, the target directory is assumed to
/// be located within the model path.
/// The path expected here is the root directory of the model's Cargo
/// package, that is the folder containing `Cargo.toml`.
pub fn from_path(path: PathBuf) -> Result<Self, Error> {
let crate_dir = path.canonicalize()?;

Expand Down Expand Up @@ -315,9 +313,9 @@ impl Watcher {
{
Ok(shape) => shape,
Err(Error::Compile) => {
// It would be better to display an error in the UI,
// where the user can actually see it. Issue:
// https://github.com/hannobraun/fornjot/issues/30
// An error is being displayed to the user via the
// `StatusReport that is passed to `load_once` above, so
// no need to do anything else here.
return None;
}
Err(err) => {
Expand Down