Skip to content

Commit f99cb28

Browse files
committed
Add missing Rails.configuration.to_prepare
1 parent 985c380 commit f99cb28

File tree

1 file changed

+20
-17
lines changed

1 file changed

+20
-17
lines changed

init.rb

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,25 @@
11
# frozen_string_literal: true
2+
Rails.configuration.to_prepare do
3+
require_relative 'lib/toggl_2_redmine'
24

3-
require_relative 'lib/toggl_2_redmine'
5+
Redmine::Plugin.register :toggl2redmine do
6+
# Package info.
7+
name 'Toggl 2 Redmine'
8+
author 'Jigarius'
9+
description 'Imports time entries from Toggl into Redmine.'
10+
version Toggl2Redmine::VERSION
11+
url 'https://github.com/jigarius/toggl2redmine'
12+
author_url 'https://jigarius.com/'
413

5-
Redmine::Plugin.register :toggl2redmine do
6-
# Package info.
7-
name 'Toggl 2 Redmine'
8-
author 'Jigar Mehta'
9-
description 'Imports time entries from Toggl into Redmine.'
10-
version Toggl2Redmine::VERSION
11-
url 'https://github.com/jigarius/toggl2redmine'
12-
author_url 'https://jigarius.com/'
14+
# Menu items.
15+
menu :application_menu,
16+
:toggl2redmine,
17+
{ controller: 't2r_import', action: 'index' },
18+
caption: 'Toggl'
19+
end
1320

14-
# Menu items.
15-
menu :application_menu,
16-
:toggl2redmine,
17-
{ controller: 't2r_import', action: 'index' },
18-
caption: 'Toggl'
21+
Rails.configuration.to_prepare do
22+
# Patches.
23+
require 'patches/time_entry_patch'
24+
end
1925
end
20-
21-
# Patches.
22-
require 'patches/time_entry'

0 commit comments

Comments
 (0)