mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
..
This commit is contained in:
parent
3f54bb537f
commit
ad35e583f2
1 changed files with 1 additions and 1 deletions
|
|
@ -90,7 +90,7 @@ impl Require {
|
|||
|
||||
fn absolute_id<'a>(lua: &Lua, id: &'a str) -> mlua::Result<Cow<'a, str>> {
|
||||
Ok(match id.strip_prefix('.') {
|
||||
None => id.into(),
|
||||
None => id.strip_suffix(".main").unwrap_or(id).into(),
|
||||
Some("main") => runtime!(lua)?.current_module()?.to_owned().into(),
|
||||
Some(rel) => format!("{}.{rel}", runtime!(lua)?.current_module()?).into(),
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue