Skip to content

Commit

Permalink
fix(plugin): remove useless part from download repo function
Browse files Browse the repository at this point in the history
  • Loading branch information
SkuldNorniern committed Jan 3, 2024
1 parent 9740d90 commit 9b45d29
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions fluere-plugin/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -104,25 +104,6 @@ impl PluginManager {
match download_plugin_from_github(name) {
Ok(_) => {
let path = home_cache_path()?.join(name.split('/').last().unwrap());
if path.starts_with(&home_cache_path()?) {
match git2::Repository::open(&path) {
Ok(repo) => match repo.find_remote("origin") {
Ok(mut remote) => {
remote.fetch(
&["refs/heads/*:refs/heads/*"],
None,
None,
)?;
}
Err(fetch_err) => {
return Err(mlua::Error::external(fetch_err))
}
},
Err(open_err) => {
return Err(mlua::Error::external(open_err))
}
}
}
match std::fs::read_to_string(path.join("init.lua")) {
Ok(code) => {
let lua_clone = self.lua.clone();
Expand Down

0 comments on commit 9b45d29

Please sign in to comment.