MCPcopy Create free account
hub / github.com/Botloader/botloader / script_url

Function script_url

components/vm/src/lib.rs:199–209  ·  view source on GitHub ↗
(script: &Script, suffix: &str)

Source from the content-addressed store, hash-verified

197}
198
199fn script_url(script: &Script, suffix: &str) -> Url {
200 if let Some(plugin_id) = &script.plugin_id {
201 return Url::parse(&format!(
202 "file:///plugins/{}/{}.{suffix}",
203 plugin_id, script.name
204 ))
205 .unwrap();
206 }
207
208 Url::parse(&format!("file:///guild_scripts/{}.{suffix}", script.name)).unwrap()
209}
210
211pub struct BlCoreOptions {
212 cloned_load_states: Rc<RefCell<ScriptsStateStore>>,

Callers 1

compile_add_scriptMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected