]> git.mxchange.org Git - jbonuscard-lib.git/commitdiff
changed order of cascade, option attributes (all code more consistent)
authorRoland Haeder <roland@mxchange.org>
Sat, 12 Mar 2016 12:58:01 +0000 (13:58 +0100)
committerRoland Haeder <roland@mxchange.org>
Sat, 12 Mar 2016 12:58:01 +0000 (13:58 +0100)
src/org/mxchange/addressbook/model/addressbook/UserAddressbook.java
src/org/mxchange/addressbook/model/addressbook/entry/UserAddressbookEntry.java

index 948695f5fd588f330c70bf80577b777dcd90a586..5f886a6d09e4d6ff7b460ea6df7419f6594aa330 100644 (file)
@@ -109,7 +109,7 @@ public class UserAddressbook implements Addressbook {
         * Connection to "users" table
         */
        @JoinColumn (name = "addressbook_user_id", nullable = false)
-       @OneToOne (targetEntity = LoginUser.class, optional = false, cascade = CascadeType.REFRESH)
+       @OneToOne (targetEntity = LoginUser.class, cascade = CascadeType.REFRESH, optional = false)
        private User addressbookUser;
 
        /**
index a90c3b9bb56a73a08e9f26652048c37914bbbb26..8af65ce2213502c97b7e3774613fc15cc6094ac2 100644 (file)
@@ -92,7 +92,7 @@ public class UserAddressbookEntry implements AddressbookEntry {
         * Connection to table "addressbooks"
         */
        @JoinColumn (name = "entry_addressbook_id", nullable = false, updatable = false)
-       @OneToOne (targetEntity = UserAddressbook.class, optional = false, cascade = CascadeType.REFRESH)
+       @OneToOne (targetEntity = UserAddressbook.class, cascade = CascadeType.REFRESH, optional = false)
        private Addressbook addressbookId;
 
        @Override