#!/usr/bin/env awk
#
# End Time - last seen
#
# Dependencies:
#   - basicFlow
#
# Example:
#   - tawk '{ print te() }' file

@include "hdr"
@include "_validate_col"

function te(        _c, _ms) {
    _c = _validate_col("timeLast", _my_timeLast)
    if (hdr()) return "Date last seen"
    _ms = gensub(/^[0-9]+\.([0-9]{3})[0-9]+/, "\\1", 1, $_c)
    return strftime("%F %T", $_c, 1) "." _ms # UTC
}
