Skip to content

Commit

Permalink
Fix extra attribute bug
Browse files Browse the repository at this point in the history
Signed-off-by: Fawzi E. Abdulfattah <iifawzie@gmail.com>
  • Loading branch information
iifawzi committed Feb 16, 2021
1 parent 88752d6 commit 9503151
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion templates/columns_definitions/column_attribute.twig
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{% if submit_attribute is defined and submit_attribute != false %}
{% set attribute = submit_attribute %}
{# MariaDB has additional parentheses #}
{% elseif column_meta['Extra'] is defined
and column_meta['Extra'] == 'on update CURRENT_TIMESTAMP' %}
and ('on update CURRENT_TIMESTAMP' in column_meta['Extra'] or 'on update CURRENT_TIMESTAMP()' in column_meta['Extra']) %}
{% set attribute = 'on update CURRENT_TIMESTAMP' %}
{% elseif extracted_columnspec['attribute'] is defined %}
{% set attribute = extracted_columnspec['attribute'] %}
Expand Down

0 comments on commit 9503151

Please sign in to comment.