Fix includes in subroutines