Period & sex

If your on your last day of your period were your not really bleeding much and guy cums in you ? Is it safe , From my knowledge during cycle you can't get pregnant but want to double check