(inputs: &[Box<dyn Value>])
| 251 | } |
| 252 | |
| 253 | pub fn date_extract_date(inputs: &[Box<dyn Value>]) -> Box<dyn Value> { |
| 254 | let argument_type = inputs[0].data_type(); |
| 255 | if argument_type.is_date() { |
| 256 | return inputs[0].clone(); |
| 257 | } |
| 258 | let timestamp = inputs[0].as_date_time().unwrap(); |
| 259 | Box::new(DateValue::new(timestamp)) |
| 260 | } |
| 261 | |
| 262 | pub fn date_current_date(_inputs: &[Box<dyn Value>]) -> Box<dyn Value> { |
| 263 | let timestamp = Utc::now().timestamp(); |
nothing calls this directly
no test coverage detected
searching dependent graphs…