                     tags.push(flvdata.tag);
                 }
                 if (tags.length) {
-                    (_hls.stream as HLSNetStream).appendTags(tags);
                     CONFIG::LOGGING {
                         Log.debug2("appending " + tags.length + " tags, max duration:" + duration);
                     }
+                    (_hls.stream as HLSNetStream).appendTags(tags);
                 }
             }
         }

                    // remember position of first tag injected after seek. it will be used for playlist sliding computation
                    _first_start_position = start_position;
                }
            }
            // update buffer min/max table indexed with continuity counter
            if (_buffer_pts[continuity] == undefined) {

            } else {
                (_buffer_pts[continuity] as BufferPTS).max = max_pts;
            }
        }

        /** Return current media position **/
