mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
code formatting
This commit is contained in:
@@ -21,7 +21,7 @@ public class FeedEntryContent extends AbstractModel {
|
||||
|
||||
@Column(length = 2048)
|
||||
private String title;
|
||||
|
||||
|
||||
@Column(length = 40)
|
||||
private String titleHash;
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ import com.sun.syndication.feed.synd.impl.ConverterForRSS090;
|
||||
|
||||
/**
|
||||
* Support description tag for RSS09
|
||||
*
|
||||
*
|
||||
*/
|
||||
public class RSS090DescriptionConverter extends ConverterForRSS090 {
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ import com.sun.syndication.io.impl.RSS090Parser;
|
||||
|
||||
/**
|
||||
* Support description tag for RSS09
|
||||
*
|
||||
*
|
||||
*/
|
||||
public class RSS090DescriptionParser extends RSS090Parser {
|
||||
|
||||
|
||||
@@ -18,11 +18,11 @@ public class FeedEntryContentService {
|
||||
* this is NOT thread-safe
|
||||
*/
|
||||
public FeedEntryContent findOrCreate(FeedEntryContent content, String baseUrl) {
|
||||
|
||||
|
||||
String contentHash = DigestUtils.sha1Hex(StringUtils.trimToEmpty(content.getContent()));
|
||||
String titleHash = DigestUtils.sha1Hex(StringUtils.trimToEmpty(content.getTitle()));
|
||||
Long existingId = feedEntryContentDAO.findExisting(contentHash, titleHash);
|
||||
|
||||
|
||||
FeedEntryContent result = null;
|
||||
if (existingId == null) {
|
||||
content.setContentHash(contentHash);
|
||||
|
||||
@@ -21,14 +21,12 @@ public class PasswordEncryptionService implements Serializable {
|
||||
|
||||
private static final Logger log = LoggerFactory.getLogger(UserDAO.class);
|
||||
|
||||
public boolean authenticate(String attemptedPassword,
|
||||
byte[] encryptedPassword, byte[] salt) {
|
||||
public boolean authenticate(String attemptedPassword, byte[] encryptedPassword, byte[] salt) {
|
||||
// Encrypt the clear-text password using the same salt that was used to
|
||||
// encrypt the original password
|
||||
byte[] encryptedAttemptedPassword = null;
|
||||
try {
|
||||
encryptedAttemptedPassword = getEncryptedPassword(
|
||||
attemptedPassword, salt);
|
||||
encryptedAttemptedPassword = getEncryptedPassword(attemptedPassword, salt);
|
||||
} catch (Exception e) {
|
||||
// should never happen
|
||||
log.error(e.getMessage(), e);
|
||||
|
||||
Reference in New Issue
Block a user