already initialized constant

This commit is contained in:
Karel Pičman 2023-05-15 12:49:05 +02:00
parent 3f05ebc5b5
commit a9f7e6238a
2 changed files with 11 additions and 9 deletions

View File

@ -156,7 +156,7 @@ jobs:
cd /opt/redmine
bundle exec rake redmine:dmsf_webdav_test_on
bundle exec rails server -u webrick -e test -d
sleep(5)
sleep 5
litmus http://localhost:3000/dmsf/webdav/dmsf_test_project admin admin
kill `cat tmp/pids/server.pid`
bundle exec rake redmine:dmsf_webdav_test_off

View File

@ -30,14 +30,16 @@ module RedmineDmsf
attr_reader :public_path
DIR_FILE = %(
<tr>
<td class=\"name\"><a href=\"%s\">%s</a></td>
<td class=\"size\">%s</td>
<td class=\"type\">%s</td>
<td class=\"mtime\">%s</td>
</tr>
)
unless const_defined?(DIR_FILE)
DIR_FILE = %(
<tr>
<td class=\"name\"><a href=\"%s\">%s</a></td>
<td class=\"size\">%s</td>
<td class=\"type\">%s</td>
<td class=\"mtime\">%s</td>
</tr>
)
end
def initialize(path, request, response, options)
raise NotFound if Setting.plugin_redmine_dmsf['dmsf_webdav'].blank?