Skip to content

Commit

Permalink
Merge branch 'LNReader:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
Batorian authored Sep 8, 2024
2 parents 6bee807 + b1778c5 commit 21ced78
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 23 deletions.
25 changes: 12 additions & 13 deletions scripts/setEnvFile.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,12 @@ let data =
os.EOL +
`RELEASE_DATE=${formattedDate}`;

let existingEnvData = '';

fs.readFile(path.join(__dirname, '..', '.env'), 'utf8', (err, existingData) => {
if (err) {
console.log(err);
return;
}
if (err) return;

const existingEnvData = existingData
existingEnvData = existingData
.split(os.EOL)
.filter(line => {
return (
Expand All @@ -32,14 +31,14 @@ fs.readFile(path.join(__dirname, '..', '.env'), 'utf8', (err, existingData) => {
);
})
.join(os.EOL);
});

if (existingEnvData) {
data += os.EOL + existingEnvData;
}
if (existingEnvData) {
data += os.EOL + existingEnvData;
}

fs.writeFile(path.join(__dirname, '..', '.env'), data, 'utf8', err => {
if (err) {
console.log(err);
}
});
fs.writeFile(path.join(__dirname, '..', '.env'), data, 'utf8', err => {
if (err) {
console.log(err);
}
});
20 changes: 10 additions & 10 deletions src/screens/settings/SettingsReaderScreen/SettingsReaderScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,34 +45,34 @@ const SettingsReaderScreen = () => {
const { bottom } = useSafeAreaInsets();
const novel = {
'artist': null,
'author': 'Kinugasa Shougo',
'author': 'LNReader-kun',
'cover':
'file:///storage/emulated/0/Android/data/com.rajarsheechatterjee.LNReader/files/Novels/lightnovelcave/16/cover.png?1717862123181',
'genres': 'Drama,Slice of Life,Psychological,School Life,Shounen',
'genres': 'Action,Hero',
'id': 16,
'inLibrary': 1,
'isLocal': 0,
'name': 'Classroom of the Elite (LN)',
'path': 'novel/classroom-of-the-elite-16091321',
'name': 'Preview Man (LN)',
'path': 'novel/preview-man-16091321',
'pluginId': 'lightnovelcave',
'status': 'Ongoing',
'summary':
'Kōdo Ikusei Senior High School, a leading prestigious school with state-of-the-art facilities where nearly 100% of students go on to university or find employment. The students there have the freedom to wear any hairstyle and bring any personal effects they desire. Kōdo Ikusei is a paradise-like school, but the truth is that only the most superior of students receive favorable treatment.The protagonist Kiyotaka Ayanokōji is a student of D-class, which is where the school dumps its “inferior” students in order to ridicule them. For a certain reason, Kiyotaka was careless on his entrance examination, and was put in D-class. After meeting Suzune Horikita and Kikyō Kushida, two other students in his class, Kiyotaka’s situation begins to change.Show More',
'To preview or not preview. A question that bothered humanity for a long time, until one day… Preview Man appeared.Show More',
'totalPages': 8,
};
const chapter = {
'bookmark': 0,
'chapterNumber': 2.1,
'chapterNumber': 1,
'id': 3722,
'isDownloaded': 1,
'name': 'Chapter V4C2.1 - A Vast Array of Thoughts Part 1',
'name': 'Chapter 1 - The rise of Preview Man',
'novelId': 16,
'page': '2',
'path': 'novel/classroom-of-the-elite-547/vol-4-chapter-2-1',
'path': 'novel/preview-man/chapter-1',
'position': 0,
'progress': 3,
'readTime': '2024-06-08 22:56:09',
'releaseTime': '14 tháng 9 năm 2021',
'readTime': '2100-01-01 00:00:00',
'releaseTime': 'January 1, 2100',
'unread': 1,
'updatedTime': null,
};
Expand Down

0 comments on commit 21ced78

Please sign in to comment.