Was the filter attached to, two plastic lines, like in Blue Bowtie's post?
Or one mechanical(metal) and one plastic, or both metal?
If both plastic, those o-rings don't generally come out when disconnecting, but it could happen......
Sure you have the correct filter?
Bolt has nothing to do with the leak, it just secures the band to hold it in place....
Next time, relieve the pressure......one way is with car running, remove fuel pump fuse.....car will eventually die as fuel is used up......pressure will drop, but as Bowtie states, there will still be some residual fuel that leaks out when the lines are disconnected....but it won't be under high pressure(if you were to turn your key on, and then off, you would have approx. 45psi of fuel pressure.....that's why is sprayed on him)....