UCF-CEN-5016 / NodeBB-UCF

This is a class specific fork of the NodeBB project for CEN 5016 taught in the Spring 2024 semester at UCF.
GNU General Public License v3.0
0 stars 74 forks source link

Converting src/middleware/helpers.js from JS to TS #152

Open VinayManukonda3321 opened 7 months ago

VinayManukonda3321 commented 7 months ago

This pull request converts src/middleware/helpers.js from JS to TS. This resolves #107

The changes I made are the following: 1.Created a new ts file named helper.ts in src/middleware 2.Made some minor changes in the following files src/controllers 404.js errors.js helpers.js src/middleware admin.js assert.js header.js headers.js helpers.js(changes are automatically made) index.js maintenance.js render.js uploads.js user.js

In TypeScript, when you have explicit type information, you need to use .default to access the default export. So, made the necessary changes in import statement in all the above files.

coveralls commented 7 months ago

Pull Request Test Coverage Report for Build 7720790076


Files with Coverage Reduction New Missed Lines %
src/middleware/helpers.js 1 93.98%
<!-- Total: 1 -->
Totals Coverage Status
Change from base Build 7649102120: -0.002%
Covered Lines: 22626
Relevant Lines: 25353

💛 - Coveralls
VinayManukonda3321 commented 7 months ago

while the linter expects LF (Line Feed) line endings all my file has CRLF (Carriage Return + Line Feed) line endings which resulted in failing a check.