Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit aa5d3fc

Browse files
committed
Road to the MIT
1 parent 13d05dc commit aa5d3fc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+392
-2283
lines changed

.docker/nginx/ssl.sh

100644100755
File mode changed.

.eslintrc.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ module.exports = {
1212
es6: true
1313
},
1414
globals: {
15-
'RL_COMMUNITY': true,
1615
'RL_ES6': true
1716
},
1817
// http://eslint.org/docs/rules/

.github/workflows/builder.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ jobs:
2626

2727
- run: yarn install --frozen-lockfile --check-files
2828
- run: yarn build
29-
- run: yarn build-pro
3029

3130
- name: Move all assets to release folder
3231
run: |

CONTRIBUTING.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,3 @@
2929

3030
1. Edit data/\_data_/\_default_/configs/application.ini
3131
2. Set 'cache_system_data' to Off
32-
33-
---
34-
35-
If you have any questions, open an issue or email support@rainloop.net.

LICENSE

Lines changed: 21 additions & 661 deletions
Large diffs are not rendered by default.

Makefile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,6 @@ rl-watch-js:
6161

6262
rl-build:
6363
@docker compose run --no-deps --rm node gulp all
64-
rl-build-pro:
65-
@docker compose run --no-deps --rm node gulp all --pro
6664

6765
yarn-install:
6866
@docker compose run --no-deps --rm node yarn install

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ Information about installing the product, check the [documentation page](http://
2222

2323
## License
2424

25-
**RainLoop Webmail (Community edition)** is released under
26-
**GNU AFFERO GENERAL PUBLIC LICENSE Version 3 (AGPL)**.
27-
http://www.gnu.org/licenses/agpl-3.0.html
25+
**RainLoop Webmail (Legacy edition)** is released under
26+
**MIT License**.
27+
https://choosealicense.com/licenses/mit/
2828

29-
Copyright (c) 2019 Rainloop Team
29+
Copyright (c) 2022 Rainloop Team

dev/App/Admin.js

Lines changed: 2 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,15 @@ import ko from 'ko';
44
import progressJs from 'progressJs';
55

66
import { root } from 'Common/Links';
7-
import { getNotification } from 'Common/Translator';
8-
import { StorageResultType, Notification } from 'Common/Enums';
9-
import { pInt, isNormal, isArray, inArray, isUnd } from 'Common/Utils';
7+
import { StorageResultType } from 'Common/Enums';
8+
import { pInt, isArray, isUnd } from 'Common/Utils';
109

1110
import * as Settings from 'Storage/Settings';
1211

1312
import AppStore from 'Stores/Admin/App';
1413
import CapaStore from 'Stores/Admin/Capa';
1514
import DomainStore from 'Stores/Admin/Domain';
1615
import PluginStore from 'Stores/Admin/Plugin';
17-
import LicenseStore from 'Stores/Admin/License';
1816
import PackageStore from 'Stores/Admin/Package';
1917
import CoreStore from 'Stores/Admin/Core';
2018
import Remote from 'Remote/Admin/Ajax';
@@ -150,40 +148,6 @@ class AdminApp extends AbstractApp {
150148
});
151149
}
152150

153-
/**
154-
* @param {boolean=} force = false
155-
*/
156-
reloadLicensing(force = false) {
157-
LicenseStore.licensingProcess(true);
158-
LicenseStore.licenseError('');
159-
Remote.licensing((result, data) => {
160-
LicenseStore.licensingProcess(false);
161-
if (StorageResultType.Success === result && data && data.Result && isNormal(data.Result.Expired)) {
162-
LicenseStore.licenseValid(true);
163-
LicenseStore.licenseExpired(pInt(data.Result.Expired));
164-
LicenseStore.licenseError('');
165-
LicenseStore.licensing(true);
166-
AppStore.prem(true);
167-
} else {
168-
if (
169-
data &&
170-
data.ErrorCode &&
171-
-1 < inArray(pInt(data.ErrorCode), [Notification.LicensingServerIsUnavailable, Notification.LicensingExpired])
172-
) {
173-
LicenseStore.licenseError(getNotification(pInt(data.ErrorCode)));
174-
LicenseStore.licensing(true);
175-
} else {
176-
if (StorageResultType.Abort === result) {
177-
LicenseStore.licenseError(getNotification(Notification.LicensingServerIsUnavailable));
178-
LicenseStore.licensing(true);
179-
} else {
180-
LicenseStore.licensing(false);
181-
}
182-
}
183-
}
184-
}, force);
185-
}
186-
187151
bootend(bootendCallback = null) {
188152
if (progressJs) {
189153
progressJs.end();

dev/Common/Globals.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,6 @@ $hcont
2626

2727
export const startMicrotime = new window.Date().getTime();
2828

29-
/**
30-
* @type {boolean}
31-
*/
32-
export const community = RL_COMMUNITY;
33-
3429
/**
3530
* @type {?}
3631
*/

dev/Screen/Admin/Settings.js

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import { SocialAdminSettings } from 'Settings/Admin/Social';
1212
import { PluginsAdminSettings } from 'Settings/Admin/Plugins';
1313
import { PackagesAdminSettings } from 'Settings/Admin/Packages';
1414
import { AboutAdminSettings } from 'Settings/Admin/About';
15+
import { BrandingAdminSettings } from 'Settings/Admin/Branding';
1516

1617
import { getApp } from 'Helper/Apps/Admin';
1718

@@ -27,16 +28,6 @@ class SettingsAdminScreen extends AbstractSettingsScreen {
2728
* @param {Function=} fCallback = null
2829
*/
2930
setupSettings(fCallback = null) {
30-
let branding = null,
31-
licensing = null;
32-
33-
if (RL_COMMUNITY) {
34-
branding = require('Settings/Admin/Branding').default;
35-
} else {
36-
branding = require('Settings/Admin/Prem/Branding').default;
37-
licensing = require('Settings/Admin/Prem/Licensing').default;
38-
}
39-
4031
addSettingsViewModel(
4132
GeneralAdminSettings,
4233
'AdminSettingsGeneral',
@@ -49,9 +40,7 @@ class SettingsAdminScreen extends AbstractSettingsScreen {
4940

5041
addSettingsViewModel(LoginAdminSettings, 'AdminSettingsLogin', 'TABS_LABELS/LABEL_LOGIN_NAME', 'login');
5142

52-
if (branding) {
53-
addSettingsViewModel(branding, 'AdminSettingsBranding', 'TABS_LABELS/LABEL_BRANDING_NAME', 'branding');
54-
}
43+
addSettingsViewModel(BrandingAdminSettings, 'AdminSettingsBranding', 'TABS_LABELS/LABEL_BRANDING_NAME', 'branding');
5544

5645
addSettingsViewModel(ContactsAdminSettings, 'AdminSettingsContacts', 'TABS_LABELS/LABEL_CONTACTS_NAME', 'contacts');
5746

@@ -68,10 +57,6 @@ class SettingsAdminScreen extends AbstractSettingsScreen {
6857

6958
addSettingsViewModel(PackagesAdminSettings, 'AdminSettingsPackages', 'TABS_LABELS/LABEL_PACKAGES_NAME', 'packages');
7059

71-
if (licensing) {
72-
addSettingsViewModel(licensing, 'AdminSettingsLicensing', 'TABS_LABELS/LABEL_LICENSING_NAME', 'licensing');
73-
}
74-
7560
addSettingsViewModel(AboutAdminSettings, 'AdminSettingsAbout', 'TABS_LABELS/LABEL_ABOUT_NAME', 'about');
7661

7762
runSettingsViewModelHooks(true);

dev/Settings/Admin/About.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import ko from 'ko';
33
import { i18n, trigger as translatorTrigger } from 'Common/Translator';
44
import { appSettingsGet, settingsGet } from 'Storage/Settings';
55

6-
import AppStore from 'Stores/Admin/App';
76
import CoreStore from 'Stores/Admin/Core';
87

98
import { getApp } from 'Helper/Apps/Admin';
@@ -27,8 +26,6 @@ class AboutAdminSettings {
2726
this.coreRemoteRelease = CoreStore.coreRemoteRelease;
2827
this.coreVersionCompare = CoreStore.coreVersionCompare;
2928

30-
this.community = RL_COMMUNITY || AppStore.community();
31-
3229
this.coreRemoteVersionHtmlDesc = ko.computed(() => {
3330
translatorTrigger();
3431
return i18n('TAB_ABOUT/HTML_NEW_VERSION', { 'VERSION': this.coreRemoteVersion() });
@@ -59,13 +56,13 @@ class AboutAdminSettings {
5956
}
6057

6158
onBuild() {
62-
if (this.access() && !this.community) {
59+
if (this.access()) {
6360
getApp().reloadCoreData();
6461
}
6562
}
6663

6764
updateCoreData() {
68-
if (!this.coreUpdating() && !this.community) {
65+
if (!this.coreUpdating()) {
6966
getApp().updateCoreData();
7067
}
7168
}

dev/Settings/Admin/Branding.js

Lines changed: 80 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,11 @@ import { settingsSaveHelperSimpleFunction, trim } from 'Common/Utils';
66
import { i18n, trigger as translatorTrigger } from 'Common/Translator';
77

88
import Remote from 'Remote/Admin/Ajax';
9-
import AppStore from 'Stores/Admin/App';
109

1110
import { settingsGet } from 'Storage/Settings';
1211

1312
class BrandingAdminSettings {
1413
constructor() {
15-
this.capa = AppStore.prem;
16-
1714
this.title = ko.observable(settingsGet('Title')).idleTrigger();
1815
this.loadingDesc = ko.observable(settingsGet('LoadingDescription')).idleTrigger();
1916
this.faviconUrl = ko.observable(settingsGet('FaviconUrl')).idleTrigger();
@@ -36,8 +33,6 @@ class BrandingAdminSettings {
3633
{ optValue: 'always', optText: i18n('TAB_BRANDING/OPTION_WELCOME_PAGE_DISPLAY_ALWAYS') }
3734
];
3835
});
39-
40-
this.community = RL_COMMUNITY || AppStore.community();
4136
}
4237

4338
onBuild() {
@@ -64,6 +59,86 @@ class BrandingAdminSettings {
6459
});
6560
});
6661
}, Magics.Time50ms);
62+
63+
_.delay(() => {
64+
const f1 = settingsSaveHelperSimpleFunction(this.loginLogo.trigger, this),
65+
f2 = settingsSaveHelperSimpleFunction(this.loginDescription.trigger, this),
66+
f3 = settingsSaveHelperSimpleFunction(this.loginCss.trigger, this),
67+
f4 = settingsSaveHelperSimpleFunction(this.userLogo.trigger, this),
68+
f5 = settingsSaveHelperSimpleFunction(this.userLogoTitle.trigger, this),
69+
f6 = settingsSaveHelperSimpleFunction(this.loginBackground.trigger, this),
70+
f7 = settingsSaveHelperSimpleFunction(this.userCss.trigger, this),
71+
f8 = settingsSaveHelperSimpleFunction(this.welcomePageUrl.trigger, this),
72+
f9 = settingsSaveHelperSimpleFunction(this.welcomePageDisplay.trigger, this),
73+
f10 = settingsSaveHelperSimpleFunction(this.userLogoMessage.trigger, this),
74+
f11 = settingsSaveHelperSimpleFunction(this.userIframeMessage.trigger, this);
75+
76+
this.loginLogo.subscribe((value) => {
77+
Remote.saveAdminConfig(f1, {
78+
'LoginLogo': trim(value)
79+
});
80+
});
81+
82+
this.loginDescription.subscribe((value) => {
83+
Remote.saveAdminConfig(f2, {
84+
'LoginDescription': trim(value)
85+
});
86+
});
87+
88+
this.loginCss.subscribe((value) => {
89+
Remote.saveAdminConfig(f3, {
90+
'LoginCss': trim(value)
91+
});
92+
});
93+
94+
this.userLogo.subscribe((value) => {
95+
Remote.saveAdminConfig(f4, {
96+
'UserLogo': trim(value)
97+
});
98+
});
99+
100+
this.userLogoTitle.subscribe((value) => {
101+
Remote.saveAdminConfig(f5, {
102+
'UserLogoTitle': trim(value)
103+
});
104+
});
105+
106+
this.userLogoMessage.subscribe((value) => {
107+
Remote.saveAdminConfig(f10, {
108+
'UserLogoMessage': trim(value)
109+
});
110+
});
111+
112+
this.userIframeMessage.subscribe((value) => {
113+
Remote.saveAdminConfig(f11, {
114+
'UserIframeMessage': trim(value)
115+
});
116+
});
117+
118+
this.loginBackground.subscribe((value) => {
119+
Remote.saveAdminConfig(f6, {
120+
'LoginBackground': trim(value)
121+
});
122+
});
123+
124+
this.userCss.subscribe((value) => {
125+
Remote.saveAdminConfig(f7, {
126+
'UserCss': trim(value)
127+
});
128+
});
129+
130+
this.welcomePageUrl.subscribe((value) => {
131+
Remote.saveAdminConfig(f8, {
132+
'WelcomePageUrl': trim(value)
133+
});
134+
});
135+
136+
this.welcomePageDisplay.subscribe((value) => {
137+
Remote.saveAdminConfig(f9, {
138+
'WelcomePageDisplay': trim(value)
139+
});
140+
});
141+
}, Magics.Time50ms);
67142
}
68143
}
69144

dev/Settings/Admin/Plugins.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import { boolToAjax } from 'Common/Utils';
88
import { settingsGet } from 'Storage/Settings';
99
import { showScreenPopup } from 'Knoin/Knoin';
1010

11-
import AppStore from 'Stores/Admin/App';
1211
import PluginStore from 'Stores/Admin/Plugin';
1312

1413
import Remote from 'Remote/Admin/Ajax';
@@ -22,8 +21,6 @@ class PluginsAdminSettings {
2221
this.plugins = PluginStore.plugins;
2322
this.pluginsError = PluginStore.plugins.error;
2423

25-
this.community = RL_COMMUNITY || AppStore.community();
26-
2724
this.visibility = ko.computed(() => (PluginStore.plugins.loading() ? 'visible' : 'hidden'));
2825

2926
this.onPluginLoadRequest = _.bind(this.onPluginLoadRequest, this);

0 commit comments

Comments
 (0)