Change moment.js invocation to avoid deprecation warning (again), closes issue #13
This commit is contained in:
		
							parent
							
								
									8b460770a7
								
							
						
					
					
						commit
						5f4a1ccac7
					
				@ -147,7 +147,7 @@ app.get('/core/:id', function(req, res){
 | 
			
		||||
 | 
			
		||||
            // Loop over elements in rows array, convert ugly UTC times to pretty local times.
 | 
			
		||||
            rows.forEach(function(row){
 | 
			
		||||
                var localDtTm = moment.utc(row.published_at);
 | 
			
		||||
                var localDtTm = moment.utc(new Date(row.published_at));
 | 
			
		||||
                localDtTm = moment(localDtTm).tz('America/New_York').format('MM-DD-YYYY HH:mm:ss');
 | 
			
		||||
                row.published_at = localDtTm;
 | 
			
		||||
                row.pubDate = moment(localDtTm).format('MM-DD-YYYY');
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user