@@ -32,7 +32,7 @@ const MONTHS: Record<string, string> = {
3232} ;
3333
3434/**
35- * Return `[ YYYY, MM, DD, HH, mm, ss ]` date string array
35+ * return `[ YYYY, MM, DD, HH, mm, ss ]` date string array
3636 */
3737export function getDateStringParts ( d ?: Date , onlyDate ?: boolean ) {
3838 d = d || new Date ( ) ;
@@ -80,11 +80,11 @@ export function logDate(d?: Date): string;
8080export function logDate ( d ?: Date | null , msSep ?: string ) : string ;
8181export function logDate ( d ?: Date | string | null , msSep ?: string ) : string {
8282 if ( typeof d === 'string' ) {
83- // LogDate (msSep)
83+ // logDate (msSep)
8484 msSep = d ;
8585 d = new Date ( ) ;
8686 } else {
87- // LogDate (d, msSep)
87+ // logDate (d, msSep)
8888 d = d || new Date ( ) ;
8989 }
9090 const [ year , month , date , hours , minutes , seconds ] = getDateStringParts ( d ) ;
@@ -152,7 +152,7 @@ export interface DateStruct {
152152}
153153
154154/**
155- * Return datetime struct.
155+ * return datetime struct.
156156 *
157157 * @return {Object } date
158158 * - {Number} YYYYMMDD, 20130401
@@ -171,8 +171,8 @@ export function datestruct(now?: Date): DateStruct {
171171 */
172172export function timestamp ( t ?: number | string ) : number | Date {
173173 if ( t ) {
174- // Convert timestamp to Date
175- // Timestamp (timestampValue)
174+ // convert timestamp to Date
175+ // timestamp (timestampValue)
176176 let v : number ;
177177 if ( typeof t === 'string' ) {
178178 v = Number ( t ) ;
@@ -184,7 +184,7 @@ export function timestamp(t?: number | string): number | Date {
184184 }
185185 return new Date ( v ) ;
186186 }
187- // Get current timestamp
187+ // get current timestamp
188188 return Math . round ( Date . now ( ) / 1000 ) ;
189189}
190190
0 commit comments