small code adaption