It isn’t advised to sleep with a leg bag holder. This is because the urine bag should always be kept below the level of your waist. Keeping the bag low stops urine from flowing back into your bladder and potentially causing an infection. When in bed, it is best to avoid using a leg bag holder and instead hang the bag beside the bed, below the level of your waist.
The same is true when showering, even though you are upright. Hang the bag from the railing below waist level while you shower so that you don’t have to worry about getting straps or a leg bag sleeve wet.