fixed a bug in the function snippet for fish