Skip to content

Commit f561bbc

Browse files
committed
simplify logic for checking prelude
1 parent 005d824 commit f561bbc

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/features/cseMachine/CseMachineLayout.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,7 @@ export class Layout {
203203
* objects into the global environment head and heap
204204
*/
205205
private static removePreludeEnv() {
206-
if (!Layout.globalEnvNode.children) return;
207-
if (Layout.globalEnvNode.children.length === 0) return;
206+
if (!Layout.globalEnvNode.children || Layout.globalEnvNode.children.length === 0) return;
208207

209208
const preludeEnvNode = Layout.globalEnvNode.children[0];
210209
const preludeEnv = preludeEnvNode.environment;

0 commit comments

Comments
 (0)