Credit for time served discretionary with court. Provides that when a court orders credit for time served in jail pending trial, etc., it may order that no time or a portion of the time be deducted from the sentence of a term of confinement when a person violates his terms of bail and is incarcerated in a local correctional facility for a violation of his terms of bail pending his trial or appeal.