Skip to content

Commit

Permalink
MNT: use Union is Fluid dataclass type for Python <3.10 support.
Browse files Browse the repository at this point in the history
  • Loading branch information
phmbressan committed May 3, 2024
1 parent f0a2fdd commit e020aaa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion rocketpy/motors/fluid.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from dataclasses import dataclass
from typing import Union

import numpy as np

Expand Down Expand Up @@ -26,7 +27,7 @@ class Fluid:
"""

name: str
density: int | float | str | list | Function
density: Union[int, float, str, list, Function]

def __post_init__(self):
"""Post initialization method.
Expand Down

0 comments on commit e020aaa

Please sign in to comment.