I have a function that takes a dataframe and performs some basic calculations. Sometimes when performing said calculations the data frame becomes empty (the details don’t matter). I’m having trouble checking if the dataframe is empty and returning nothing. My code is below:

```
function do_stuff(my_dataframe)
# Nifty calculations
if nrow(my_dataframe) == 0:
return
# More calculations here
return my_datafram
end
```

For some reason, julia is throwing this error: LoadError: syntax: incomplete: “function” at /home/ec2-user/environment/my_file.jl:17 requires end

Is there a syntax error? Is there a proper way to interrupt a function?