Added adding function for transactions