mirror of
https://github.com/eliasstepanik/strudel-docker.git
synced 2026-01-13 06:38:31 +00:00
fix: duplicate example
This commit is contained in:
parent
f8d1e9e004
commit
ac2e450e38
@ -138,7 +138,7 @@ export function updateUserCode(code) {
|
||||
let activePattern = getSetting('activePattern');
|
||||
// check if code is that of an example tune
|
||||
const [example] = Object.entries(tunes).find(([_, tune]) => tune === code) || [];
|
||||
if (example) {
|
||||
if (example && (!activePattern || activePattern === example)) {
|
||||
// select example
|
||||
setActivePattern(example);
|
||||
return;
|
||||
@ -187,5 +187,6 @@ export function duplicateActivePattern() {
|
||||
}
|
||||
|
||||
export function setActivePattern(key) {
|
||||
console.log('set', key);
|
||||
settingsMap.setKey('activePattern', key);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user