add duration to metadata object