Fix for using functions as PSDs