move unpure up
This commit is contained in:
parent
86248328cc
commit
452827630b
1 changed files with 8 additions and 7 deletions
|
|
@ -74,6 +74,14 @@ export function repl({
|
||||||
return silence;
|
return silence;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// helper to get a patternified pure value out
|
||||||
|
function unpure(pat) {
|
||||||
|
if (pat._Pattern) {
|
||||||
|
return pat.__pure;
|
||||||
|
}
|
||||||
|
return pat;
|
||||||
|
}
|
||||||
|
|
||||||
const setPattern = async (pattern, autostart = true) => {
|
const setPattern = async (pattern, autostart = true) => {
|
||||||
pattern = editPattern?.(pattern) || pattern;
|
pattern = editPattern?.(pattern) || pattern;
|
||||||
await scheduler.setPattern(pattern, autostart);
|
await scheduler.setPattern(pattern, autostart);
|
||||||
|
|
@ -90,13 +98,6 @@ export function repl({
|
||||||
return silence;
|
return silence;
|
||||||
};
|
};
|
||||||
|
|
||||||
function unpure(pat) {
|
|
||||||
if (pat._Pattern) {
|
|
||||||
return pat.__pure;
|
|
||||||
}
|
|
||||||
return pat;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Changes the global tempo to the given cycles per minute
|
* Changes the global tempo to the given cycles per minute
|
||||||
*
|
*
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue