Skip to content

Bug: Missing import causes calculateFutureScPrice to fail at runtime #85

@sach2004

Description

@sach2004

Description

The calculateFutureScPrice function in djed-sdk/src/djed/stableCoin.js references a helper function that is not imported in the file. This causes a ReferenceError at runtime when the function is invoked.

Steps to Reproduce

  1. Import calculateFutureScPrice from the djed-sdk
  2. Call the function with valid parameters
  3. Observe ReferenceError being thrown

Expected Behavior

The function should execute successfully and return the calculated future stablecoin price.

Actual Behavior

The function throws a ReferenceError because a required helper function is not in scope.

Proposed Solution

Update the import statement in stableCoin.js to include the missing helper function from ../helpers.js, consistent with how other files in the same directory (like djed.js and system.js) handle their imports.

@Zahnentferner please assign this issue to me! would love to solve this issue!!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions